dashboard icon indicating copy to clipboard operation
dashboard copied to clipboard

Replace Flavor with Instance Type and Preferences (KubeVirt)

Open cschieder opened this issue 2 years ago • 2 comments

Step 4) Initial Nodes, KubeVirt Settings Replace VM Flavor with Instance Type and Preferences.

Behavior Both fields are not required. Preference can only be selected after Instance Type. Instance Type alone can be selected. View button works just as it does with VM Flavor, showing details of both (or only Instance Type, if no Preference is selected)

Both are dropdowns, both have 2 sections/categories. "Custom" and "Kubermatic"

I'd like to try putting both dropdowns in the same line but we will need to see about average content length.

This change affects

  • Cluster Create
  • Machine Deployment Edit
  • Machine Deployment Details page, Nodes unfoldable area (feel free to check if I've forgotten a location)

cschieder avatar Oct 05 '22 15:10 cschieder

Can you please add some more details in description like where do the options of this new Preferences dropdown come from? Also, is Instance Type just a renamed version of VM Flavor and which API payload properties do these dropdowns use? I see that the API payload is still the same in Swagger (for KubeVirt settings).

Waseem826 avatar Oct 07 '22 12:10 Waseem826

Note the mapping between the API type and the NodeSpec type:

  • KubevirtNodeSpec type InstancetypeMatcher contains a "Kind" that can be : VirtualMachineInstancetype / VirtualMachineClusterInstancetype
  • in apiv2.VirtualMachineInstancetypeCategory: allowed values are: "custom" (for VirtualMachineClusterInstancetype) and "standard" (for VirtualMachineInstancetype)

API endpoints:

  • /api/v2/projects/{project_id}/clusters/{cluster_id}/providers/kubevirt/instancetypes: return the list of all instancetypes, kubermatic and custom. In NodeSpec "kubermatic" -> VirtualMachineInstancetype, "custom" -> VirtualMachineClusterInstancetype
  • /api/v2/projects/{project_id}/clusters/{cluster_id}/providers/kubevirt/preferences Same for preferences.

hdurand0710 avatar Oct 07 '22 12:10 hdurand0710

Closed by mistake, wrong ref in my API PR.

hdurand0710 avatar Nov 08 '22 15:11 hdurand0710