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
Add Virtual Hardware tab to Create VM Wizard #3237
Add Virtual Hardware tab to Create VM Wizard #3237
Conversation
@glekner I think this would be similar to what we had for the disk tab where we don't have a specific action for CD-ROMs but incorporate it into the "Add disk" flow. I can put together some designs for it today. I also wonder how this is impacted by advanced > virtual hardware, that could be the right place for this too. |
c9cdc67
to
265ae41
Compare
@glekner ya I think we need to determine the priority of the action. I don't see a lot of reasons to add CD-ROMs manually. @jelkosz do you have any thoughts on this? It seems Windows Guest tools are the primary reason we'd see CD-ROMs here. They really are edge cases when we consider there are no physical CD-ROMs to pass through to the VM it's just another PVC. |
4829b55
to
4561234
Compare
0495163
to
db2a1a8
Compare
db2a1a8
to
d154c8c
Compare
05f1719
to
1b00f13
Compare
e260dcc
to
4e9afb3
Compare
f09100a
to
b4cab28
Compare
export const getAvailableCDName = (cds: CD[]) => { | ||
let index = 1; | ||
let name = `cd-drive-${index}`; | ||
cds.sort(compareCDS).forEach((cd) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I still think #3237 (comment) is a better solution:
Please do not modify the input array with sort as this is an unexpected behaviour for this function
bus: DiskBus.VIRTIO, | ||
}); | ||
|
||
const addButton = () => ( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
there is no need for this to be a function
), | ||
}); | ||
|
||
const getActions = ( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
these actions seem to be the same as the one in vm-wizard-storage-row. Can we export them from there and delete them here?
<CDSimpleRow | ||
data={{ ...restData, name }} | ||
validation={{ | ||
name: validations.name || validations.url || validations.container || validations.pvc, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
shouldn't this be content now?
@@ -77,7 +67,7 @@ const menuActionDelete = ( | |||
), | |||
}); | |||
|
|||
const getActions = ( | |||
export const getActions = ( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what is this export for?
b4cab28
to
761d83b
Compare
|
d770ebd
to
cac72a8
Compare
@@ -217,7 +218,7 @@ export type VMWizardStorage = { | |||
|
|||
export type VMWizardStorageWithWrappers = VMWizardStorage & { | |||
diskWrapper: DiskWrapper; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
let's make it all optional to be consistent
frontend/.vscode/settings.json
Outdated
@@ -34,6 +34,9 @@ | |||
"**/bower_components": true, | |||
"**/.cache-loader": true, | |||
"**/public/dist": true | |||
}, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
shouldn't this rather go into a separate PR?
two nits, but otherwise looks good |
cac72a8
to
f2baf11
Compare
done @suomiy |
<VMCDsTable | ||
columnClasses={cdTableColumnClasses} | ||
data={virtualStorages} | ||
customData={{ isDisabled: disableAddCD, withProgress, removeStorage, wizardReduxID }} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why is the editing and deleting disabled once we reach 2 cds?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@suomiy thats a design decision. A bit controversial I agree, but a reasoning is that it is not needed to have more than 2 - you can have 1 for OS and 1 for drivers but there is no need to have a 3th. ...aaaand we should expose only things which are actually needed...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, sorry, I've misunderstood your comment. Also the delete and edit is disabled here, so it is incorrect I agree. Only the add has to be disabled.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it should still reference isLocked
f2baf11
to
c9f463a
Compare
c9f463a
to
2eb9b87
Compare
/lgtm |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: glekner, suomiy The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
/retest |
/retest Please review the full test history for this PR and help us cut down flakes. |
1 similar comment
/retest Please review the full test history for this PR and help us cut down flakes. |
/retest |
Changes
DiskModal
to support CD-ROM Add/EditType
Column from Disks table (Create VM Storage Tab, Overview Disks tab)