Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix rendering of VMware floppy drive #5041

Merged

Conversation

mzazrivec
Copy link
Contributor

Before:
floppy-before

After:
floppy-after

@agrare Would this be correct fix for the linked bz? Thanks.

https://bugzilla.redhat.com/show_bug.cgi?id=1650501

@@ -55,6 +55,8 @@ def calculate_disk_name(disk)
"Hard Disk (SCSI #{disk.location})"
when "scsi-passthru"
"Generic SCSI (#{disk.location})"
when "floppy"
"Floppy Drive (SIO #{disk.location})"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you use (#{disk.controller_type} #{disk.location}) for all of these? Hard-coding Hard Disk (SCSI isn't correct since you can have disks on e.g. IDE

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You don't want to have SIO, SCSI, etc. hardcoded for floppy drives only, or for all disk types in general?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In general

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So for consistency with the rest of this I'm fine with this, but I think we should revisit this and use the disk.controller_type for the rest of these.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

# select distinct(controller_type) from disks order by controller_type;
 controller_type  
------------------
 amazon
 azure
 google
 ide
 IDE
 openstack
 OpenStack Volume
 scsi
 sio
 virtio
 virtio_scsi
(11 rows)

These are all controller types that I have in my devel DB. Does that show all possible types? Why is there both ide and IDE? I'm trying to figure out what would things look like in UI once we take it directly from DB.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For amazon I also see "EBS Volume", great question on ide vs IDE my guess is that vmware has lowercase scsi, sio, ide and it looks like scvmm is the one adding IDE.

I'm not sure why the cloud providers were just putting the name in the controller_type, that doesn't make a whole lot of sense :) I'd rather nothing if it isn't something like scsi/ide/virtio ¯_(ツ)_/¯

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@agrare Besides what we're discussing here (probably a material for different PR), do you approve changes in this PR? Thanks.

@miq-bot
Copy link
Member

miq-bot commented Dec 4, 2018

Checked commit mzazrivec@114a262 with ruby 2.3.3, rubocop 0.52.1, haml-lint 0.20.0, and yamllint 1.10.0
1 file checked, 0 offenses detected
Everything looks fine. 🍰

@himdel himdel self-assigned this Dec 7, 2018
@himdel himdel added this to the Sprint 101 Ending Dec 17, 2018 milestone Dec 7, 2018
@himdel himdel merged commit aa35608 into ManageIQ:master Dec 7, 2018
@mzazrivec mzazrivec deleted the fix_rendering_of_vmware_floppy_drive branch December 7, 2018 12:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants