From 6398ee4c988e1d398e74d769ff9799413bc7bf77 Mon Sep 17 00:00:00 2001 From: Joseph Callen Date: Tue, 22 Oct 2024 15:12:16 -0400 Subject: [PATCH] Add VMGroup to VSphere Provider workspace For the machine api operator to support vm-host based zonal a single new field of `vmGroup` needs to be added that will indicate the vCenter cluster group to add a newly created virtual machine into. --- machine/v1beta1/types_vsphereprovider.go | 4 ++++ machine/v1beta1/zz_generated.swagger_doc_generated.go | 1 + openapi/generated_openapi/zz_generated.openapi.go | 7 +++++++ openapi/openapi.json | 4 ++++ 4 files changed, 16 insertions(+) diff --git a/machine/v1beta1/types_vsphereprovider.go b/machine/v1beta1/types_vsphereprovider.go index f458cbf6eff..0a0567d630a 100644 --- a/machine/v1beta1/types_vsphereprovider.go +++ b/machine/v1beta1/types_vsphereprovider.go @@ -190,6 +190,10 @@ type Workspace struct { // ResourcePool is the resource pool in which VMs are created/located. // +optional ResourcePool string `gcfg:"resourcepool-path,omitempty" json:"resourcePool,omitempty"` + // vmGroup is the cluster vm group in which virtual machines will be added for vm host group based zonal. + // +openshift:validation:featureGate=VSphereHostVMGroupZonal + // +optional + VMGroup string `gcfg:"vmGroup,omitempty" json:"vmGroup,omitempty"` } // VSphereMachineProviderStatus is the type that will be embedded in a Machine.Status.ProviderStatus field. diff --git a/machine/v1beta1/zz_generated.swagger_doc_generated.go b/machine/v1beta1/zz_generated.swagger_doc_generated.go index 5bba232bf7f..99540dde5e0 100644 --- a/machine/v1beta1/zz_generated.swagger_doc_generated.go +++ b/machine/v1beta1/zz_generated.swagger_doc_generated.go @@ -822,6 +822,7 @@ var map_Workspace = map[string]string{ "folder": "Folder is the folder in which VMs are created/located.", "datastore": "Datastore is the datastore in which VMs are created/located.", "resourcePool": "ResourcePool is the resource pool in which VMs are created/located.", + "vmGroup": "vmGroup is the cluster vm group in which virtual machines will be added for vm host group based zonal.", } func (Workspace) SwaggerDoc() map[string]string { diff --git a/openapi/generated_openapi/zz_generated.openapi.go b/openapi/generated_openapi/zz_generated.openapi.go index 58627d9b0d8..0f1644258bb 100644 --- a/openapi/generated_openapi/zz_generated.openapi.go +++ b/openapi/generated_openapi/zz_generated.openapi.go @@ -38843,6 +38843,13 @@ func schema_openshift_api_machine_v1beta1_Workspace(ref common.ReferenceCallback Format: "", }, }, + "vmGroup": { + SchemaProps: spec.SchemaProps{ + Description: "vmGroup is the cluster vm group in which virtual machines will be added for vm host group based zonal.", + Type: []string{"string"}, + Format: "", + }, + }, }, }, }, diff --git a/openapi/openapi.json b/openapi/openapi.json index bd2640373c8..9c4386f1a0e 100644 --- a/openapi/openapi.json +++ b/openapi/openapi.json @@ -22430,6 +22430,10 @@ "server": { "description": "Server is the IP address or FQDN of the vSphere endpoint.", "type": "string" + }, + "vmGroup": { + "description": "vmGroup is the cluster vm group in which virtual machines will be added for vm host group based zonal.", + "type": "string" } } },