From 906bb28eac2277d71a11c35dded4578db38f6598 Mon Sep 17 00:00:00 2001 From: Joseph Callen Date: Wed, 14 Aug 2024 09:17:06 -0400 Subject: [PATCH] vSphere - add host and vm based zonal New feature gate VSphereHostVMGroupZonal Add RegionType and ZoneType fields to VSpherePlatformFailureDomainSpec to specify region and zone failure domain types. Add VSphereFailureDomainAffinity type that contains three fields required for vm-host zonal: VMGroup, HostGroup and VMHostRule. Add VSphereFailureDomainAffinity to VSpherePlatformTopology Create additional unit tests to cover the introduction of vm-host zonal provisioning types. Add VMGroup in a machine(s) workspace. --- .../VSphereHostVMGroupZonal.yaml | 562 ++++ config/v1/types_infrastructure.go | 75 +- ...1_infrastructures-CustomNoUpgrade.crd.yaml | 135 +- ...erator_01_infrastructures-Default.crd.yaml | 127 +- ...frastructures-DevPreviewNoUpgrade.crd.yaml | 135 +- ...rastructures-TechPreviewNoUpgrade.crd.yaml | 135 +- config/v1/zz_generated.deepcopy.go | 18 + ..._generated.featuregated-crd-manifests.yaml | 1 + .../AAA_ungated.yaml | 127 +- .../BareMetalLoadBalancer.yaml | 127 +- .../GCPClusterHostedDNS.yaml | 127 +- .../GCPLabelsTags.yaml | 127 +- .../VSphereControlPlaneMachineSet.yaml | 127 +- .../VSphereHostVMGroupZonal.yaml | 1996 +++++++++++++ .../VSphereMultiNetworks.yaml | 127 +- .../VSphereMultiVCenters.yaml | 127 +- .../v1/zz_generated.swagger_doc_generated.go | 25 +- features.md | 1 + features/features.go | 7 + machine/v1beta1/types_vsphereprovider.go | 3 + .../zz_generated.swagger_doc_generated.go | 1 + ...controllerconfigs-CustomNoUpgrade.crd.yaml | 137 +- ...nfig_01_controllerconfigs-Default.crd.yaml | 129 +- ...rollerconfigs-DevPreviewNoUpgrade.crd.yaml | 137 +- ...ollerconfigs-TechPreviewNoUpgrade.crd.yaml | 137 +- ..._generated.featuregated-crd-manifests.yaml | 1 + .../AAA_ungated.yaml | 129 +- .../BareMetalLoadBalancer.yaml | 129 +- .../GCPClusterHostedDNS.yaml | 129 +- .../GCPLabelsTags.yaml | 129 +- .../VSphereControlPlaneMachineSet.yaml | 129 +- .../VSphereHostVMGroupZonal.yaml | 2535 +++++++++++++++++ .../VSphereMultiNetworks.yaml | 129 +- .../VSphereMultiVCenters.yaml | 129 +- .../generated_openapi/zz_generated.openapi.go | 80 +- openapi/openapi.json | 49 + ...1_infrastructures-CustomNoUpgrade.crd.yaml | 135 +- ...erator_01_infrastructures-Default.crd.yaml | 127 +- ...frastructures-DevPreviewNoUpgrade.crd.yaml | 135 +- ...rastructures-TechPreviewNoUpgrade.crd.yaml | 135 +- ...controllerconfigs-CustomNoUpgrade.crd.yaml | 137 +- ...nfig_01_controllerconfigs-Default.crd.yaml | 129 +- ...rollerconfigs-DevPreviewNoUpgrade.crd.yaml | 137 +- ...ollerconfigs-TechPreviewNoUpgrade.crd.yaml | 137 +- .../featureGate-Hypershift-Default.yaml | 3 + ...reGate-Hypershift-DevPreviewNoUpgrade.yaml | 3 + ...eGate-Hypershift-TechPreviewNoUpgrade.yaml | 3 + .../featureGate-SelfManagedHA-Default.yaml | 3 + ...ate-SelfManagedHA-DevPreviewNoUpgrade.yaml | 3 + ...te-SelfManagedHA-TechPreviewNoUpgrade.yaml | 3 + tests/generator.go | 8 + tests/suite_test.go | 4 +- 52 files changed, 9220 insertions(+), 100 deletions(-) create mode 100644 config/v1/tests/infrastructures.config.openshift.io/VSphereHostVMGroupZonal.yaml create mode 100644 config/v1/zz_generated.featuregated-crd-manifests/infrastructures.config.openshift.io/VSphereHostVMGroupZonal.yaml create mode 100644 machineconfiguration/v1/zz_generated.featuregated-crd-manifests/controllerconfigs.machineconfiguration.openshift.io/VSphereHostVMGroupZonal.yaml diff --git a/config/v1/tests/infrastructures.config.openshift.io/VSphereHostVMGroupZonal.yaml b/config/v1/tests/infrastructures.config.openshift.io/VSphereHostVMGroupZonal.yaml new file mode 100644 index 00000000000..b952861acb8 --- /dev/null +++ b/config/v1/tests/infrastructures.config.openshift.io/VSphereHostVMGroupZonal.yaml @@ -0,0 +1,562 @@ +apiVersion: apiextensions.k8s.io/v1 # Hack because controller-gen complains if we don't have this +name: "Infrastructure" +crdName: infrastructures.config.openshift.io +featureGate: VSphereHostVMGroupZonal +tests: + onCreate: + - name: Should not be able to have regionAffinity type Datacenter or HostGroup if zoneAffinity type is HostGroup + initial: | + apiVersion: config.openshift.io/v1 + kind: Infrastructure + spec: + cloudConfig: + key: config + name: cloud-provider-config + platformSpec: + type: VSphere + vsphere: + failureDomains: + - name: generated-failure-domain + region: generated-region + server: server1.dev.cluster.com + regionAffinity: + type: Datacenter + zoneAffinity: + type: HostGroup + vmGroup: vmg1 + hostGroup: hg1 + vmHostRule: mhr1 + topology: + computeCluster: /IBMCloud/host/vcs-8e-workload + datacenter: IBMCloud + datastore: /IBMCloud/datastore/mdcnc-ds-shared + networks: + - ocp-ci-seg-13 + resourcePool: /IBMCloud/host/vcs-8e-workload/Resources + template: /IBMCloud/vm/ngirard-dev-rqh5s-rhcos-generated-region-generated-zone + zone: generated-zone + nodeNetworking: + external: {} + internal: {} + vcenters: + - datacenters: + - IBMCloud + port: 443 + server: server1.dev.cluster.com + expectedError: "when zoneAffinity type is HostGroup, regionAffinity type must be ComputeCluster" + - name: Should not be able to have regionAffinity type ComputeCluster or HostGroup if zoneAffinity type is ComputeCluster + initial: | + apiVersion: config.openshift.io/v1 + kind: Infrastructure + spec: + cloudConfig: + key: config + name: cloud-provider-config + platformSpec: + type: VSphere + vsphere: + failureDomains: + - name: generated-failure-domain + region: generated-region + server: server1.dev.cluster.com + regionAffinity: + type: ComputeCluster + zoneAffinity: + type: ComputeCluster + topology: + computeCluster: /IBMCloud/host/vcs-8e-workload + datacenter: IBMCloud + datastore: /IBMCloud/datastore/mdcnc-ds-shared + networks: + - ocp-ci-seg-13 + resourcePool: /IBMCloud/host/vcs-8e-workload/Resources + template: /IBMCloud/vm/ngirard-dev-rqh5s-rhcos-generated-region-generated-zone + zone: generated-zone + nodeNetworking: + external: {} + internal: {} + vcenters: + - datacenters: + - IBMCloud + port: 443 + server: server1.dev.cluster.com + expectedError: "when zoneAffinity type is ComputeCluster, regionAffinity type must be Datacenter" + - name: Should not be able to have missing vmGroup, hostGroup and vmHostRule fields if zone type is HostGroup + initial: | + apiVersion: config.openshift.io/v1 + kind: Infrastructure + spec: + cloudConfig: + key: config + name: cloud-provider-config + platformSpec: + type: VSphere + vsphere: + failureDomains: + - name: generated-failure-domain + region: generated-region + server: server1.dev.cluster.com + regionAffinity: + type: ComputeCluster + zoneAffinity: + type: HostGroup + topology: + computeCluster: /IBMCloud/host/vcs-8e-workload + datacenter: IBMCloud + datastore: /IBMCloud/datastore/mdcnc-ds-shared + networks: + - ocp-ci-seg-13 + resourcePool: /IBMCloud/host/vcs-8e-workload/Resources + template: /IBMCloud/vm/ngirard-dev-rqh5s-rhcos-generated-region-generated-zone + zone: generated-zone + nodeNetworking: + external: {} + internal: {} + vcenters: + - datacenters: + - IBMCloud + port: 443 + server: server1.dev.cluster.com + expectedError: "when type is HostGroup, vmGroup field must be defined" + - name: Should not be able to have missing vmGroup field if zone type is HostGroup + initial: | + apiVersion: config.openshift.io/v1 + kind: Infrastructure + spec: + cloudConfig: + key: config + name: cloud-provider-config + platformSpec: + type: VSphere + vsphere: + failureDomains: + - name: generated-failure-domain + region: generated-region + server: server1.dev.cluster.com + regionAffinity: + type: ComputeCluster + zoneAffinity: + type: HostGroup + hostGroup: hg1 + vmHostRule: vmhr1 + topology: + computeCluster: /IBMCloud/host/vcs-8e-workload + datacenter: IBMCloud + datastore: /IBMCloud/datastore/mdcnc-ds-shared + networks: + - ocp-ci-seg-13 + resourcePool: /IBMCloud/host/vcs-8e-workload/Resources + template: /IBMCloud/vm/ngirard-dev-rqh5s-rhcos-generated-region-generated-zone + zone: generated-zone + nodeNetworking: + external: {} + internal: {} + vcenters: + - datacenters: + - IBMCloud + port: 443 + server: server1.dev.cluster.com + expectedError: "when type is HostGroup, vmGroup field must be defined" + - name: Should not be able to have missing hostGroup field if zone type is HostGroup + initial: | + apiVersion: config.openshift.io/v1 + kind: Infrastructure + spec: + cloudConfig: + key: config + name: cloud-provider-config + platformSpec: + type: VSphere + vsphere: + failureDomains: + - name: generated-failure-domain + region: generated-region + server: server1.dev.cluster.com + regionAffinity: + type: ComputeCluster + zoneAffinity: + type: HostGroup + vmGroup: hg1 + vmHostRule: vmhr1 + topology: + computeCluster: /IBMCloud/host/vcs-8e-workload + datacenter: IBMCloud + datastore: /IBMCloud/datastore/mdcnc-ds-shared + networks: + - ocp-ci-seg-13 + resourcePool: /IBMCloud/host/vcs-8e-workload/Resources + template: /IBMCloud/vm/ngirard-dev-rqh5s-rhcos-generated-region-generated-zone + zone: generated-zone + nodeNetworking: + external: {} + internal: {} + vcenters: + - datacenters: + - IBMCloud + port: 443 + server: server1.dev.cluster.com + expectedError: "when type is HostGroup, hostGroup field must be defined" + - name: Should not be able to have vmGroup field if zone type is not HostGroup + initial: | + apiVersion: config.openshift.io/v1 + kind: Infrastructure + spec: + cloudConfig: + key: config + name: cloud-provider-config + platformSpec: + type: VSphere + vsphere: + failureDomains: + - name: generated-failure-domain + region: generated-region + server: server1.dev.cluster.com + regionAffinity: + type: Datacenter + zoneAffinity: + type: ComputeCluster + vmGroup: hg1 + topology: + computeCluster: /IBMCloud/host/vcs-8e-workload + datacenter: IBMCloud + datastore: /IBMCloud/datastore/mdcnc-ds-shared + networks: + - ocp-ci-seg-13 + resourcePool: /IBMCloud/host/vcs-8e-workload/Resources + template: /IBMCloud/vm/ngirard-dev-rqh5s-rhcos-generated-region-generated-zone + zone: generated-zone + nodeNetworking: + external: {} + internal: {} + vcenters: + - datacenters: + - IBMCloud + port: 443 + server: server1.dev.cluster.com + expectedError: "when vmGroup field is defined, type must be HostGroup" + - name: Should not be able to have hostGroup field if zone type is not HostGroup + initial: | + apiVersion: config.openshift.io/v1 + kind: Infrastructure + spec: + cloudConfig: + key: config + name: cloud-provider-config + platformSpec: + type: VSphere + vsphere: + failureDomains: + - name: generated-failure-domain + region: generated-region + server: server1.dev.cluster.com + regionAffinity: + type: Datacenter + zoneAffinity: + type: ComputeCluster + hostGroup: hg1 + topology: + computeCluster: /IBMCloud/host/vcs-8e-workload + datacenter: IBMCloud + datastore: /IBMCloud/datastore/mdcnc-ds-shared + networks: + - ocp-ci-seg-13 + resourcePool: /IBMCloud/host/vcs-8e-workload/Resources + template: /IBMCloud/vm/ngirard-dev-rqh5s-rhcos-generated-region-generated-zone + zone: generated-zone + nodeNetworking: + external: {} + internal: {} + vcenters: + - datacenters: + - IBMCloud + port: 443 + server: server1.dev.cluster.com + expectedError: "when hostGroup field is defined, type must be HostGroup" + - name: Should not be able to have vmHostRule field if zone type is not HostGroup + initial: | + apiVersion: config.openshift.io/v1 + kind: Infrastructure + spec: + cloudConfig: + key: config + name: cloud-provider-config + platformSpec: + type: VSphere + vsphere: + failureDomains: + - name: generated-failure-domain + region: generated-region + server: server1.dev.cluster.com + regionAffinity: + type: Datacenter + zoneAffinity: + type: ComputeCluster + vmHostRule: vmhr1 + topology: + computeCluster: /IBMCloud/host/vcs-8e-workload + datacenter: IBMCloud + datastore: /IBMCloud/datastore/mdcnc-ds-shared + networks: + - ocp-ci-seg-13 + resourcePool: /IBMCloud/host/vcs-8e-workload/Resources + template: /IBMCloud/vm/ngirard-dev-rqh5s-rhcos-generated-region-generated-zone + zone: generated-zone + nodeNetworking: + external: {} + internal: {} + vcenters: + - datacenters: + - IBMCloud + port: 443 + server: server1.dev.cluster.com + expectedError: "when vmHostRule field is defined, type must be HostGroup" + - name: Should not be able to have empty vmHostRule field if zone type is HostGroup + initial: | + apiVersion: config.openshift.io/v1 + kind: Infrastructure + spec: + cloudConfig: + key: config + name: cloud-provider-config + platformSpec: + type: VSphere + vsphere: + failureDomains: + - name: generated-failure-domain + region: generated-region + server: server1.dev.cluster.com + regionAffinity: + type: ComputeCluster + zoneAffinity: + type: HostGroup + vmGroup: vmg1 + hostGroup: hg1 + topology: + computeCluster: /IBMCloud/host/vcs-8e-workload + datacenter: IBMCloud + datastore: /IBMCloud/datastore/mdcnc-ds-shared + networks: + - ocp-ci-seg-13 + resourcePool: /IBMCloud/host/vcs-8e-workload/Resources + template: /IBMCloud/vm/ngirard-dev-rqh5s-rhcos-generated-region-generated-zone + zone: generated-zone + nodeNetworking: + external: {} + internal: {} + vcenters: + - datacenters: + - IBMCloud + port: 443 + server: server1.dev.cluster.com + expectedError: "when type is HostGroup, vmHostRule field must be defined" + - name: Should be able to create a vm-host zonal infrastructure spec + initial: | + apiVersion: config.openshift.io/v1 + kind: Infrastructure + spec: + cloudConfig: + key: config + name: cloud-provider-config + platformSpec: + type: VSphere + vsphere: + failureDomains: + - name: generated-failure-domain + server: server1.dev.cluster.com + region: generated-region + zone: generated-zone + regionAffinity: + type: ComputeCluster + zoneAffinity: + type: HostGroup + vmGroup: vmg1 + hostGroup: hg1 + vmHostRule: mhr1 + topology: + computeCluster: /IBMCloud/host/vcs-8e-workload + datacenter: IBMCloud + datastore: /IBMCloud/datastore/mdcnc-ds-shared + networks: + - ocp-ci-seg-13 + resourcePool: /IBMCloud/host/vcs-8e-workload/Resources + template: /IBMCloud/vm/ngirard-dev-rqh5s-rhcos-generated-region-generated-zone + nodeNetworking: + external: {} + internal: {} + vcenters: + - datacenters: + - IBMCloud + port: 443 + server: server1.dev.cluster.com + expected: | + apiVersion: config.openshift.io/v1 + kind: Infrastructure + spec: + cloudConfig: + key: config + name: cloud-provider-config + platformSpec: + type: VSphere + vsphere: + failureDomains: + - name: generated-failure-domain + region: generated-region + server: server1.dev.cluster.com + zone: generated-zone + regionAffinity: + type: ComputeCluster + zoneAffinity: + type: HostGroup + vmGroup: vmg1 + hostGroup: hg1 + vmHostRule: mhr1 + topology: + computeCluster: /IBMCloud/host/vcs-8e-workload + datacenter: IBMCloud + datastore: /IBMCloud/datastore/mdcnc-ds-shared + networks: + - ocp-ci-seg-13 + resourcePool: /IBMCloud/host/vcs-8e-workload/Resources + template: /IBMCloud/vm/ngirard-dev-rqh5s-rhcos-generated-region-generated-zone + nodeNetworking: + external: {} + internal: {} + vcenters: + - datacenters: + - IBMCloud + port: 443 + server: server1.dev.cluster.com + - name: Should be able to create a pre 4.18 non-vm-host zonal infrastructure spec + initial: | + apiVersion: config.openshift.io/v1 + kind: Infrastructure + spec: + cloudConfig: + key: config + name: cloud-provider-config + platformSpec: + type: VSphere + vsphere: + failureDomains: + - name: generated-failure-domain + region: generated-region + server: server1.dev.cluster.com + topology: + computeCluster: /IBMCloud/host/vcs-8e-workload + datacenter: IBMCloud + datastore: /IBMCloud/datastore/mdcnc-ds-shared + networks: + - ocp-ci-seg-13 + resourcePool: /IBMCloud/host/vcs-8e-workload/Resources + template: /IBMCloud/vm/ngirard-dev-rqh5s-rhcos-generated-region-generated-zone + zone: generated-zone + nodeNetworking: + external: {} + internal: {} + vcenters: + - datacenters: + - IBMCloud + port: 443 + server: server1.dev.cluster.com + expected: | + apiVersion: config.openshift.io/v1 + kind: Infrastructure + spec: + cloudConfig: + key: config + name: cloud-provider-config + platformSpec: + type: VSphere + vsphere: + failureDomains: + - name: generated-failure-domain + region: generated-region + server: server1.dev.cluster.com + topology: + computeCluster: /IBMCloud/host/vcs-8e-workload + datacenter: IBMCloud + datastore: /IBMCloud/datastore/mdcnc-ds-shared + networks: + - ocp-ci-seg-13 + resourcePool: /IBMCloud/host/vcs-8e-workload/Resources + template: /IBMCloud/vm/ngirard-dev-rqh5s-rhcos-generated-region-generated-zone + zone: generated-zone + nodeNetworking: + external: {} + internal: {} + vcenters: + - datacenters: + - IBMCloud + port: 443 + server: server1.dev.cluster.com + - name: Should be able to create a 4.18+ non-vm-host zonal infrastructure spec + initial: | + apiVersion: config.openshift.io/v1 + kind: Infrastructure + spec: + cloudConfig: + key: config + name: cloud-provider-config + platformSpec: + type: VSphere + vsphere: + failureDomains: + - name: generated-failure-domain + region: generated-region + server: server1.dev.cluster.com + regionAffinity: + type: Datacenter + zoneAffinity: + type: ComputeCluster + topology: + computeCluster: /IBMCloud/host/vcs-8e-workload + datacenter: IBMCloud + datastore: /IBMCloud/datastore/mdcnc-ds-shared + networks: + - ocp-ci-seg-13 + resourcePool: /IBMCloud/host/vcs-8e-workload/Resources + template: /IBMCloud/vm/ngirard-dev-rqh5s-rhcos-generated-region-generated-zone + zone: generated-zone + nodeNetworking: + external: {} + internal: {} + vcenters: + - datacenters: + - IBMCloud + port: 443 + server: server1.dev.cluster.com + expected: | + apiVersion: config.openshift.io/v1 + kind: Infrastructure + spec: + cloudConfig: + key: config + name: cloud-provider-config + platformSpec: + type: VSphere + vsphere: + failureDomains: + - name: generated-failure-domain + region: generated-region + server: server1.dev.cluster.com + regionAffinity: + type: Datacenter + zoneAffinity: + type: ComputeCluster + topology: + computeCluster: /IBMCloud/host/vcs-8e-workload + datacenter: IBMCloud + datastore: /IBMCloud/datastore/mdcnc-ds-shared + networks: + - ocp-ci-seg-13 + resourcePool: /IBMCloud/host/vcs-8e-workload/Resources + template: /IBMCloud/vm/ngirard-dev-rqh5s-rhcos-generated-region-generated-zone + zone: generated-zone + nodeNetworking: + external: {} + internal: {} + vcenters: + - datacenters: + - IBMCloud + port: 443 + server: server1.dev.cluster.com diff --git a/config/v1/types_infrastructure.go b/config/v1/types_infrastructure.go index 392d128c111..d45535f8e3f 100644 --- a/config/v1/types_infrastructure.go +++ b/config/v1/types_infrastructure.go @@ -1148,8 +1148,22 @@ type VSpherePlatformLoadBalancer struct { Type PlatformLoadBalancerType `json:"type,omitempty"` } -// VSpherePlatformFailureDomainSpec holds the region and zone failure domain and -// the vCenter topology of that failure domain. +// The VSphereFailureDomainType is a string representation of a failure domain +// type. There are three supportable types: HostGroup, ComputeCluster and Datacenter +type VSphereFailureDomainType string + +const ( + // HostGroupFailureDomain is a failure domain for a vCenter vm-host group. + HostGroupFailureDomain VSphereFailureDomainType = "HostGroup" + // ComputeClusterFailureDomain is a failure domain for a vCenter compute cluster. + ComputeClusterFailureDomain VSphereFailureDomainType = "ComputeCluster" + // DatacenterFailureDomain is a failure domain for a vCenter datacenter. + DatacenterFailureDomain VSphereFailureDomainType = "Datacenter" +) + +// VSpherePlatformFailureDomainSpec holds the region and zone failure domain and the vCenter topology of that failure domain. +// +kubebuilder:validation:XValidation:rule="has(self.zoneAffinity) && self.zoneAffinity.type == 'HostGroup' ? has(self.regionAffinity) && self.regionAffinity.type == 'ComputeCluster' : true",message="when zoneAffinity type is HostGroup, regionAffinity type must be ComputeCluster" +// +kubebuilder:validation:XValidation:rule="has(self.zoneAffinity) && self.zoneAffinity.type == 'ComputeCluster' ? has(self.regionAffinity) && self.regionAffinity.type == 'Datacenter' : true",message="when zoneAffinity type is ComputeCluster, regionAffinity type must be Datacenter" type VSpherePlatformFailureDomainSpec struct { // name defines the arbitrary but unique name // of a failure domain. @@ -1174,6 +1188,22 @@ type VSpherePlatformFailureDomainSpec struct { // +kubebuilder:validation:Required Zone string `json:"zone"` + // affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + // a vm-host group of type Virtual Machine and Host respectively. Is also + // contains the VMHostRule which is an affinity vm-host rule in vCenter. + // +openshift:validation:featureGate=VSphereHostVMGroupZonal + // +kubebuilder:validation:Optional + // +optional + RegionAffinity VSphereFailureDomainAffinity `json:"regionAffinity,omitempty"` + + // affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + // a vm-host group of type Virtual Machine and Host respectively. Is also + // contains the VMHostRule which is an affinity vm-host rule in vCenter. + // +openshift:validation:featureGate=VSphereHostVMGroupZonal + // +kubebuilder:validation:Optional + // +optional + ZoneAffinity VSphereFailureDomainAffinity `json:"zoneAffinity,omitempty"` + // server is the fully-qualified domain name or the IP address of the vCenter server. // +kubebuilder:validation:Required // +kubebuilder:validation:MinLength=1 @@ -1263,6 +1293,47 @@ type VSpherePlatformTopology struct { Template string `json:"template,omitempty"` } +// VSphereFailureDomainAffinity contains the vCenter cluster vm-host group (virtual machine and host types) +// and the vm-host affinity rule that together creates a affinity configuration for vm-host based zonal. +// This configuration within vCenter creates the required association between a failure domain, virtual machines +// and ESXi hosts to create a vm-host based zone. +// +kubebuilder:validation:XValidation:rule="has(self.type) && self.type == 'HostGroup' ? has(self.hostGroup) : true",message="when type is HostGroup, hostGroup field must be defined" +// +kubebuilder:validation:XValidation:rule="has(self.type) && self.type != 'HostGroup' ? !has(self.hostGroup) : true",message="when hostGroup field is defined, type must be HostGroup" +// +kubebuilder:validation:XValidation:rule="has(self.type) && self.type == 'HostGroup' ? has(self.vmGroup) : true",message="when type is HostGroup, vmGroup field must be defined" +// +kubebuilder:validation:XValidation:rule="has(self.type) && self.type != 'HostGroup' ? !has(self.vmGroup) : true",message="when vmGroup field is defined, type must be HostGroup" +// +kubebuilder:validation:XValidation:rule="has(self.type) && self.type == 'HostGroup' ? has(self.vmHostRule) : true",message="when type is HostGroup, vmHostRule field must be defined" +// +kubebuilder:validation:XValidation:rule="has(self.type) && self.type != 'HostGroup' ? !has(self.vmHostRule) : true",message="when vmHostRule field is defined, type must be HostGroup" +// +union +type VSphereFailureDomainAffinity struct { + // +kubebuilder:validation:Optional + // +openshift:validation:FeatureGateAwareEnum:featureGate=VSphereHostVMGroupZonal,enum=HostGroup;ComputeCluster;Datacenter + // +unionDiscriminator + Type VSphereFailureDomainType `json:"type"` + // vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + // This field is required when the VSphereFailureDomain ZoneType is HostGroup + // +openshift:validation:featureGate=VSphereHostVMGroupZonal + // +kubebuilder:validation:MaxLength=80 + // +optional + // +unionMember,optional + VMGroup string `json:"vmGroup,omitempty"` + + // hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + // This field is required when the VSphereFailureDomain ZoneType is HostGroup + // +openshift:validation:featureGate=VSphereHostVMGroupZonal + // +kubebuilder:validation:MaxLength=80 + // +optional + // +unionMember,optional + HostGroup string `json:"hostGroup,omitempty"` + + // vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + // This field is required when the VSphereFailureDomain ZoneType is HostGroup + // +openshift:validation:featureGate=VSphereHostVMGroupZonal + // +kubebuilder:validation:MaxLength=80 + // +optional + // +unionMember,optional + VMHostRule string `json:"vmHostRule,omitempty"` +} + // VSpherePlatformVCenterSpec stores the vCenter connection fields. // This is used by the vSphere CCM. type VSpherePlatformVCenterSpec struct { diff --git a/config/v1/zz_generated.crd-manifests/0000_10_config-operator_01_infrastructures-CustomNoUpgrade.crd.yaml b/config/v1/zz_generated.crd-manifests/0000_10_config-operator_01_infrastructures-CustomNoUpgrade.crd.yaml index 28e7a04c3d8..76ee0050f1e 100644 --- a/config/v1/zz_generated.crd-manifests/0000_10_config-operator_01_infrastructures-CustomNoUpgrade.crd.yaml +++ b/config/v1/zz_generated.crd-manifests/0000_10_config-operator_01_infrastructures-CustomNoUpgrade.crd.yaml @@ -608,9 +608,9 @@ spec: failureDomains contains the definition of region, zone and the vCenter topology. If this is omitted failure domains (regions and zones) will not be used. items: - description: |- - VSpherePlatformFailureDomainSpec holds the region and zone failure domain and - the vCenter topology of that failure domain. + description: VSpherePlatformFailureDomainSpec holds the + region and zone failure domain and the vCenter topology + of that failure domain. properties: name: description: |- @@ -627,6 +627,65 @@ spec: maxLength: 80 minLength: 1 type: string + regionAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + enum: + - HostGroup + - ComputeCluster + - Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' server: anyOf: - format: ipv4 @@ -727,6 +786,65 @@ spec: maxLength: 80 minLength: 1 type: string + zoneAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + enum: + - HostGroup + - ComputeCluster + - Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' required: - name - region @@ -734,6 +852,17 @@ spec: - topology - zone type: object + x-kubernetes-validations: + - message: when zoneAffinity type is HostGroup, regionAffinity + type must be ComputeCluster + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''HostGroup'' ? has(self.regionAffinity) && self.regionAffinity.type + == ''ComputeCluster'' : true' + - message: when zoneAffinity type is ComputeCluster, regionAffinity + type must be Datacenter + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''ComputeCluster'' ? has(self.regionAffinity) && + self.regionAffinity.type == ''Datacenter'' : true' type: array x-kubernetes-list-map-keys: - name diff --git a/config/v1/zz_generated.crd-manifests/0000_10_config-operator_01_infrastructures-Default.crd.yaml b/config/v1/zz_generated.crd-manifests/0000_10_config-operator_01_infrastructures-Default.crd.yaml index f2f1d4fb836..b5ee9971316 100644 --- a/config/v1/zz_generated.crd-manifests/0000_10_config-operator_01_infrastructures-Default.crd.yaml +++ b/config/v1/zz_generated.crd-manifests/0000_10_config-operator_01_infrastructures-Default.crd.yaml @@ -608,9 +608,9 @@ spec: failureDomains contains the definition of region, zone and the vCenter topology. If this is omitted failure domains (regions and zones) will not be used. items: - description: |- - VSpherePlatformFailureDomainSpec holds the region and zone failure domain and - the vCenter topology of that failure domain. + description: VSpherePlatformFailureDomainSpec holds the + region and zone failure domain and the vCenter topology + of that failure domain. properties: name: description: |- @@ -627,6 +627,61 @@ spec: maxLength: 80 minLength: 1 type: string + regionAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' server: anyOf: - format: ipv4 @@ -727,6 +782,61 @@ spec: maxLength: 80 minLength: 1 type: string + zoneAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' required: - name - region @@ -734,6 +844,17 @@ spec: - topology - zone type: object + x-kubernetes-validations: + - message: when zoneAffinity type is HostGroup, regionAffinity + type must be ComputeCluster + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''HostGroup'' ? has(self.regionAffinity) && self.regionAffinity.type + == ''ComputeCluster'' : true' + - message: when zoneAffinity type is ComputeCluster, regionAffinity + type must be Datacenter + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''ComputeCluster'' ? has(self.regionAffinity) && + self.regionAffinity.type == ''Datacenter'' : true' type: array x-kubernetes-list-map-keys: - name diff --git a/config/v1/zz_generated.crd-manifests/0000_10_config-operator_01_infrastructures-DevPreviewNoUpgrade.crd.yaml b/config/v1/zz_generated.crd-manifests/0000_10_config-operator_01_infrastructures-DevPreviewNoUpgrade.crd.yaml index e6155bdb923..d1f019d0b8c 100644 --- a/config/v1/zz_generated.crd-manifests/0000_10_config-operator_01_infrastructures-DevPreviewNoUpgrade.crd.yaml +++ b/config/v1/zz_generated.crd-manifests/0000_10_config-operator_01_infrastructures-DevPreviewNoUpgrade.crd.yaml @@ -608,9 +608,9 @@ spec: failureDomains contains the definition of region, zone and the vCenter topology. If this is omitted failure domains (regions and zones) will not be used. items: - description: |- - VSpherePlatformFailureDomainSpec holds the region and zone failure domain and - the vCenter topology of that failure domain. + description: VSpherePlatformFailureDomainSpec holds the + region and zone failure domain and the vCenter topology + of that failure domain. properties: name: description: |- @@ -627,6 +627,65 @@ spec: maxLength: 80 minLength: 1 type: string + regionAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + enum: + - HostGroup + - ComputeCluster + - Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' server: anyOf: - format: ipv4 @@ -727,6 +786,65 @@ spec: maxLength: 80 minLength: 1 type: string + zoneAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + enum: + - HostGroup + - ComputeCluster + - Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' required: - name - region @@ -734,6 +852,17 @@ spec: - topology - zone type: object + x-kubernetes-validations: + - message: when zoneAffinity type is HostGroup, regionAffinity + type must be ComputeCluster + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''HostGroup'' ? has(self.regionAffinity) && self.regionAffinity.type + == ''ComputeCluster'' : true' + - message: when zoneAffinity type is ComputeCluster, regionAffinity + type must be Datacenter + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''ComputeCluster'' ? has(self.regionAffinity) && + self.regionAffinity.type == ''Datacenter'' : true' type: array x-kubernetes-list-map-keys: - name diff --git a/config/v1/zz_generated.crd-manifests/0000_10_config-operator_01_infrastructures-TechPreviewNoUpgrade.crd.yaml b/config/v1/zz_generated.crd-manifests/0000_10_config-operator_01_infrastructures-TechPreviewNoUpgrade.crd.yaml index 41806e139e4..9fe3f557c2c 100644 --- a/config/v1/zz_generated.crd-manifests/0000_10_config-operator_01_infrastructures-TechPreviewNoUpgrade.crd.yaml +++ b/config/v1/zz_generated.crd-manifests/0000_10_config-operator_01_infrastructures-TechPreviewNoUpgrade.crd.yaml @@ -608,9 +608,9 @@ spec: failureDomains contains the definition of region, zone and the vCenter topology. If this is omitted failure domains (regions and zones) will not be used. items: - description: |- - VSpherePlatformFailureDomainSpec holds the region and zone failure domain and - the vCenter topology of that failure domain. + description: VSpherePlatformFailureDomainSpec holds the + region and zone failure domain and the vCenter topology + of that failure domain. properties: name: description: |- @@ -627,6 +627,65 @@ spec: maxLength: 80 minLength: 1 type: string + regionAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + enum: + - HostGroup + - ComputeCluster + - Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' server: anyOf: - format: ipv4 @@ -727,6 +786,65 @@ spec: maxLength: 80 minLength: 1 type: string + zoneAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + enum: + - HostGroup + - ComputeCluster + - Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' required: - name - region @@ -734,6 +852,17 @@ spec: - topology - zone type: object + x-kubernetes-validations: + - message: when zoneAffinity type is HostGroup, regionAffinity + type must be ComputeCluster + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''HostGroup'' ? has(self.regionAffinity) && self.regionAffinity.type + == ''ComputeCluster'' : true' + - message: when zoneAffinity type is ComputeCluster, regionAffinity + type must be Datacenter + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''ComputeCluster'' ? has(self.regionAffinity) && + self.regionAffinity.type == ''Datacenter'' : true' type: array x-kubernetes-list-map-keys: - name diff --git a/config/v1/zz_generated.deepcopy.go b/config/v1/zz_generated.deepcopy.go index 06934699847..4c6c00d960d 100644 --- a/config/v1/zz_generated.deepcopy.go +++ b/config/v1/zz_generated.deepcopy.go @@ -5822,9 +5822,27 @@ func (in *UsernamePrefix) DeepCopy() *UsernamePrefix { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *VSphereFailureDomainAffinity) DeepCopyInto(out *VSphereFailureDomainAffinity) { + *out = *in + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VSphereFailureDomainAffinity. +func (in *VSphereFailureDomainAffinity) DeepCopy() *VSphereFailureDomainAffinity { + if in == nil { + return nil + } + out := new(VSphereFailureDomainAffinity) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *VSpherePlatformFailureDomainSpec) DeepCopyInto(out *VSpherePlatformFailureDomainSpec) { *out = *in + out.RegionAffinity = in.RegionAffinity + out.ZoneAffinity = in.ZoneAffinity in.Topology.DeepCopyInto(&out.Topology) return } diff --git a/config/v1/zz_generated.featuregated-crd-manifests.yaml b/config/v1/zz_generated.featuregated-crd-manifests.yaml index fa5dd4e31d3..5c611f2cfb4 100644 --- a/config/v1/zz_generated.featuregated-crd-manifests.yaml +++ b/config/v1/zz_generated.featuregated-crd-manifests.yaml @@ -314,6 +314,7 @@ infrastructures.config.openshift.io: - GCPClusterHostedDNS - GCPLabelsTags - VSphereControlPlaneMachineSet + - VSphereHostVMGroupZonal - VSphereMultiNetworks - VSphereMultiVCenters FilenameOperatorName: config-operator diff --git a/config/v1/zz_generated.featuregated-crd-manifests/infrastructures.config.openshift.io/AAA_ungated.yaml b/config/v1/zz_generated.featuregated-crd-manifests/infrastructures.config.openshift.io/AAA_ungated.yaml index 4bb24a55924..45877857074 100644 --- a/config/v1/zz_generated.featuregated-crd-manifests/infrastructures.config.openshift.io/AAA_ungated.yaml +++ b/config/v1/zz_generated.featuregated-crd-manifests/infrastructures.config.openshift.io/AAA_ungated.yaml @@ -608,9 +608,9 @@ spec: failureDomains contains the definition of region, zone and the vCenter topology. If this is omitted failure domains (regions and zones) will not be used. items: - description: |- - VSpherePlatformFailureDomainSpec holds the region and zone failure domain and - the vCenter topology of that failure domain. + description: VSpherePlatformFailureDomainSpec holds the + region and zone failure domain and the vCenter topology + of that failure domain. properties: name: description: |- @@ -627,6 +627,61 @@ spec: maxLength: 80 minLength: 1 type: string + regionAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' server: description: server is the fully-qualified domain name or the IP address of the vCenter server. @@ -708,6 +763,61 @@ spec: maxLength: 80 minLength: 1 type: string + zoneAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' required: - name - region @@ -715,6 +825,17 @@ spec: - topology - zone type: object + x-kubernetes-validations: + - message: when zoneAffinity type is HostGroup, regionAffinity + type must be ComputeCluster + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''HostGroup'' ? has(self.regionAffinity) && self.regionAffinity.type + == ''ComputeCluster'' : true' + - message: when zoneAffinity type is ComputeCluster, regionAffinity + type must be Datacenter + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''ComputeCluster'' ? has(self.regionAffinity) && + self.regionAffinity.type == ''Datacenter'' : true' type: array x-kubernetes-list-map-keys: - name diff --git a/config/v1/zz_generated.featuregated-crd-manifests/infrastructures.config.openshift.io/BareMetalLoadBalancer.yaml b/config/v1/zz_generated.featuregated-crd-manifests/infrastructures.config.openshift.io/BareMetalLoadBalancer.yaml index 65abe99b849..b5494b2aa42 100644 --- a/config/v1/zz_generated.featuregated-crd-manifests/infrastructures.config.openshift.io/BareMetalLoadBalancer.yaml +++ b/config/v1/zz_generated.featuregated-crd-manifests/infrastructures.config.openshift.io/BareMetalLoadBalancer.yaml @@ -608,9 +608,9 @@ spec: failureDomains contains the definition of region, zone and the vCenter topology. If this is omitted failure domains (regions and zones) will not be used. items: - description: |- - VSpherePlatformFailureDomainSpec holds the region and zone failure domain and - the vCenter topology of that failure domain. + description: VSpherePlatformFailureDomainSpec holds the + region and zone failure domain and the vCenter topology + of that failure domain. properties: name: description: |- @@ -627,6 +627,61 @@ spec: maxLength: 80 minLength: 1 type: string + regionAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' server: description: server is the fully-qualified domain name or the IP address of the vCenter server. @@ -707,6 +762,61 @@ spec: maxLength: 80 minLength: 1 type: string + zoneAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' required: - name - region @@ -714,6 +824,17 @@ spec: - topology - zone type: object + x-kubernetes-validations: + - message: when zoneAffinity type is HostGroup, regionAffinity + type must be ComputeCluster + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''HostGroup'' ? has(self.regionAffinity) && self.regionAffinity.type + == ''ComputeCluster'' : true' + - message: when zoneAffinity type is ComputeCluster, regionAffinity + type must be Datacenter + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''ComputeCluster'' ? has(self.regionAffinity) && + self.regionAffinity.type == ''Datacenter'' : true' type: array x-kubernetes-list-map-keys: - name diff --git a/config/v1/zz_generated.featuregated-crd-manifests/infrastructures.config.openshift.io/GCPClusterHostedDNS.yaml b/config/v1/zz_generated.featuregated-crd-manifests/infrastructures.config.openshift.io/GCPClusterHostedDNS.yaml index 379e991aed5..2ded7a925b8 100644 --- a/config/v1/zz_generated.featuregated-crd-manifests/infrastructures.config.openshift.io/GCPClusterHostedDNS.yaml +++ b/config/v1/zz_generated.featuregated-crd-manifests/infrastructures.config.openshift.io/GCPClusterHostedDNS.yaml @@ -608,9 +608,9 @@ spec: failureDomains contains the definition of region, zone and the vCenter topology. If this is omitted failure domains (regions and zones) will not be used. items: - description: |- - VSpherePlatformFailureDomainSpec holds the region and zone failure domain and - the vCenter topology of that failure domain. + description: VSpherePlatformFailureDomainSpec holds the + region and zone failure domain and the vCenter topology + of that failure domain. properties: name: description: |- @@ -627,6 +627,61 @@ spec: maxLength: 80 minLength: 1 type: string + regionAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' server: description: server is the fully-qualified domain name or the IP address of the vCenter server. @@ -707,6 +762,61 @@ spec: maxLength: 80 minLength: 1 type: string + zoneAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' required: - name - region @@ -714,6 +824,17 @@ spec: - topology - zone type: object + x-kubernetes-validations: + - message: when zoneAffinity type is HostGroup, regionAffinity + type must be ComputeCluster + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''HostGroup'' ? has(self.regionAffinity) && self.regionAffinity.type + == ''ComputeCluster'' : true' + - message: when zoneAffinity type is ComputeCluster, regionAffinity + type must be Datacenter + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''ComputeCluster'' ? has(self.regionAffinity) && + self.regionAffinity.type == ''Datacenter'' : true' type: array x-kubernetes-list-map-keys: - name diff --git a/config/v1/zz_generated.featuregated-crd-manifests/infrastructures.config.openshift.io/GCPLabelsTags.yaml b/config/v1/zz_generated.featuregated-crd-manifests/infrastructures.config.openshift.io/GCPLabelsTags.yaml index a068bb5766c..0436060418c 100644 --- a/config/v1/zz_generated.featuregated-crd-manifests/infrastructures.config.openshift.io/GCPLabelsTags.yaml +++ b/config/v1/zz_generated.featuregated-crd-manifests/infrastructures.config.openshift.io/GCPLabelsTags.yaml @@ -608,9 +608,9 @@ spec: failureDomains contains the definition of region, zone and the vCenter topology. If this is omitted failure domains (regions and zones) will not be used. items: - description: |- - VSpherePlatformFailureDomainSpec holds the region and zone failure domain and - the vCenter topology of that failure domain. + description: VSpherePlatformFailureDomainSpec holds the + region and zone failure domain and the vCenter topology + of that failure domain. properties: name: description: |- @@ -627,6 +627,61 @@ spec: maxLength: 80 minLength: 1 type: string + regionAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' server: description: server is the fully-qualified domain name or the IP address of the vCenter server. @@ -707,6 +762,61 @@ spec: maxLength: 80 minLength: 1 type: string + zoneAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' required: - name - region @@ -714,6 +824,17 @@ spec: - topology - zone type: object + x-kubernetes-validations: + - message: when zoneAffinity type is HostGroup, regionAffinity + type must be ComputeCluster + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''HostGroup'' ? has(self.regionAffinity) && self.regionAffinity.type + == ''ComputeCluster'' : true' + - message: when zoneAffinity type is ComputeCluster, regionAffinity + type must be Datacenter + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''ComputeCluster'' ? has(self.regionAffinity) && + self.regionAffinity.type == ''Datacenter'' : true' type: array x-kubernetes-list-map-keys: - name diff --git a/config/v1/zz_generated.featuregated-crd-manifests/infrastructures.config.openshift.io/VSphereControlPlaneMachineSet.yaml b/config/v1/zz_generated.featuregated-crd-manifests/infrastructures.config.openshift.io/VSphereControlPlaneMachineSet.yaml index dbeb8c46d21..149f6f5e527 100644 --- a/config/v1/zz_generated.featuregated-crd-manifests/infrastructures.config.openshift.io/VSphereControlPlaneMachineSet.yaml +++ b/config/v1/zz_generated.featuregated-crd-manifests/infrastructures.config.openshift.io/VSphereControlPlaneMachineSet.yaml @@ -608,9 +608,9 @@ spec: failureDomains contains the definition of region, zone and the vCenter topology. If this is omitted failure domains (regions and zones) will not be used. items: - description: |- - VSpherePlatformFailureDomainSpec holds the region and zone failure domain and - the vCenter topology of that failure domain. + description: VSpherePlatformFailureDomainSpec holds the + region and zone failure domain and the vCenter topology + of that failure domain. properties: name: description: |- @@ -627,6 +627,61 @@ spec: maxLength: 80 minLength: 1 type: string + regionAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' server: description: server is the fully-qualified domain name or the IP address of the vCenter server. @@ -722,6 +777,61 @@ spec: maxLength: 80 minLength: 1 type: string + zoneAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' required: - name - region @@ -729,6 +839,17 @@ spec: - topology - zone type: object + x-kubernetes-validations: + - message: when zoneAffinity type is HostGroup, regionAffinity + type must be ComputeCluster + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''HostGroup'' ? has(self.regionAffinity) && self.regionAffinity.type + == ''ComputeCluster'' : true' + - message: when zoneAffinity type is ComputeCluster, regionAffinity + type must be Datacenter + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''ComputeCluster'' ? has(self.regionAffinity) && + self.regionAffinity.type == ''Datacenter'' : true' type: array x-kubernetes-list-map-keys: - name diff --git a/config/v1/zz_generated.featuregated-crd-manifests/infrastructures.config.openshift.io/VSphereHostVMGroupZonal.yaml b/config/v1/zz_generated.featuregated-crd-manifests/infrastructures.config.openshift.io/VSphereHostVMGroupZonal.yaml new file mode 100644 index 00000000000..5e65aa6ab14 --- /dev/null +++ b/config/v1/zz_generated.featuregated-crd-manifests/infrastructures.config.openshift.io/VSphereHostVMGroupZonal.yaml @@ -0,0 +1,1996 @@ +apiVersion: apiextensions.k8s.io/v1 +kind: CustomResourceDefinition +metadata: + annotations: + api-approved.openshift.io: https://github.com/openshift/api/pull/470 + api.openshift.io/filename-cvo-runlevel: "0000_10" + api.openshift.io/filename-operator: config-operator + api.openshift.io/filename-ordering: "01" + feature-gate.release.openshift.io/VSphereHostVMGroupZonal: "true" + release.openshift.io/bootstrap-required: "true" + name: infrastructures.config.openshift.io +spec: + group: config.openshift.io + names: + kind: Infrastructure + listKind: InfrastructureList + plural: infrastructures + singular: infrastructure + scope: Cluster + versions: + - name: v1 + schema: + openAPIV3Schema: + description: |- + Infrastructure holds cluster-wide information about Infrastructure. The canonical name is `cluster` + + Compatibility level 1: Stable within a major release for a minimum of 12 months or 3 minor releases (whichever is longer). + properties: + apiVersion: + description: |- + APIVersion defines the versioned schema of this representation of an object. + Servers should convert recognized schemas to the latest internal value, and + may reject unrecognized values. + More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + type: string + kind: + description: |- + Kind is a string value representing the REST resource this object represents. + Servers may infer this from the endpoint the client submits requests to. + Cannot be updated. + In CamelCase. + More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + type: string + metadata: + type: object + spec: + description: spec holds user settable values for configuration + properties: + cloudConfig: + description: |- + cloudConfig is a reference to a ConfigMap containing the cloud provider configuration file. + This configuration file is used to configure the Kubernetes cloud provider integration + when using the built-in cloud provider integration or the external cloud controller manager. + The namespace for this config map is openshift-config. + + cloudConfig should only be consumed by the kube_cloud_config controller. + The controller is responsible for using the user configuration in the spec + for various platforms and combining that with the user provided ConfigMap in this field + to create a stitched kube cloud config. + The controller generates a ConfigMap `kube-cloud-config` in `openshift-config-managed` namespace + with the kube cloud config is stored in `cloud.conf` key. + All the clients are expected to use the generated ConfigMap only. + properties: + key: + description: Key allows pointing to a specific key/value inside + of the configmap. This is useful for logical file references. + type: string + name: + type: string + type: object + platformSpec: + description: |- + platformSpec holds desired information specific to the underlying + infrastructure provider. + properties: + alibabaCloud: + description: AlibabaCloud contains settings specific to the Alibaba + Cloud infrastructure provider. + type: object + aws: + description: AWS contains settings specific to the Amazon Web + Services infrastructure provider. + properties: + serviceEndpoints: + description: |- + serviceEndpoints list contains custom endpoints which will override default + service endpoint of AWS Services. + There must be only one ServiceEndpoint for a service. + items: + description: |- + AWSServiceEndpoint store the configuration of a custom url to + override existing defaults of AWS Services. + properties: + name: + description: |- + name is the name of the AWS service. + The list of all the service names can be found at https://docs.aws.amazon.com/general/latest/gr/aws-service-information.html + This must be provided and cannot be empty. + pattern: ^[a-z0-9-]+$ + type: string + url: + description: |- + url is fully qualified URI with scheme https, that overrides the default generated + endpoint for a client. + This must be provided and cannot be empty. + pattern: ^https:// + type: string + type: object + type: array + x-kubernetes-list-type: atomic + type: object + azure: + description: Azure contains settings specific to the Azure infrastructure + provider. + type: object + baremetal: + description: BareMetal contains settings specific to the BareMetal + platform. + properties: + apiServerInternalIPs: + description: |- + apiServerInternalIPs are the IP addresses to contact the Kubernetes API + server that can be used by components inside the cluster, like kubelets + using the infrastructure rather than Kubernetes networking. These are the + IPs for a self-hosted load balancer in front of the API servers. + In dual stack clusters this list contains two IP addresses, one from IPv4 + family and one from IPv6. + In single stack clusters a single IP address is expected. + When omitted, values from the status.apiServerInternalIPs will be used. + Once set, the list cannot be completely removed (but its second entry can). + items: + description: IP is an IP address (for example, "10.0.0.0" + or "fd00::"). + maxLength: 39 + minLength: 1 + type: string + x-kubernetes-validations: + - message: value must be a valid IP address + rule: isIP(self) + maxItems: 2 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - message: apiServerInternalIPs must contain at most one IPv4 + address and at most one IPv6 address + rule: 'size(self) == 2 && isIP(self[0]) && isIP(self[1]) + ? ip(self[0]).family() != ip(self[1]).family() : true' + ingressIPs: + description: |- + ingressIPs are the external IPs which route to the default ingress + controller. The IPs are suitable targets of a wildcard DNS record used to + resolve default route host names. + In dual stack clusters this list contains two IP addresses, one from IPv4 + family and one from IPv6. + In single stack clusters a single IP address is expected. + When omitted, values from the status.ingressIPs will be used. + Once set, the list cannot be completely removed (but its second entry can). + items: + description: IP is an IP address (for example, "10.0.0.0" + or "fd00::"). + maxLength: 39 + minLength: 1 + type: string + x-kubernetes-validations: + - message: value must be a valid IP address + rule: isIP(self) + maxItems: 2 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - message: ingressIPs must contain at most one IPv4 address + and at most one IPv6 address + rule: 'size(self) == 2 && isIP(self[0]) && isIP(self[1]) + ? ip(self[0]).family() != ip(self[1]).family() : true' + machineNetworks: + description: |- + machineNetworks are IP networks used to connect all the OpenShift cluster + nodes. Each network is provided in the CIDR format and should be IPv4 or IPv6, + for example "10.0.0.0/8" or "fd00::/8". + items: + description: CIDR is an IP address range in CIDR notation + (for example, "10.0.0.0/8" or "fd00::/8"). + maxLength: 43 + minLength: 1 + type: string + x-kubernetes-validations: + - message: value must be a valid CIDR network address + rule: isCIDR(self) + maxItems: 32 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - rule: self.all(x, self.exists_one(y, x == y)) + type: object + x-kubernetes-validations: + - message: apiServerInternalIPs list is required once set + rule: '!has(oldSelf.apiServerInternalIPs) || has(self.apiServerInternalIPs)' + - message: ingressIPs list is required once set + rule: '!has(oldSelf.ingressIPs) || has(self.ingressIPs)' + equinixMetal: + description: EquinixMetal contains settings specific to the Equinix + Metal infrastructure provider. + type: object + external: + description: |- + ExternalPlatformType represents generic infrastructure provider. + Platform-specific components should be supplemented separately. + properties: + platformName: + default: Unknown + description: |- + PlatformName holds the arbitrary string representing the infrastructure provider name, expected to be set at the installation time. + This field is solely for informational and reporting purposes and is not expected to be used for decision-making. + type: string + x-kubernetes-validations: + - message: platform name cannot be changed once set + rule: oldSelf == 'Unknown' || self == oldSelf + type: object + gcp: + description: GCP contains settings specific to the Google Cloud + Platform infrastructure provider. + type: object + ibmcloud: + description: IBMCloud contains settings specific to the IBMCloud + infrastructure provider. + type: object + kubevirt: + description: Kubevirt contains settings specific to the kubevirt + infrastructure provider. + type: object + nutanix: + description: Nutanix contains settings specific to the Nutanix + infrastructure provider. + properties: + failureDomains: + description: |- + failureDomains configures failure domains information for the Nutanix platform. + When set, the failure domains defined here may be used to spread Machines across + prism element clusters to improve fault tolerance of the cluster. + items: + description: NutanixFailureDomain configures failure domain + information for the Nutanix platform. + properties: + cluster: + description: |- + cluster is to identify the cluster (the Prism Element under management of the Prism Central), + in which the Machine's VM will be created. The cluster identifier (uuid or name) can be obtained + from the Prism Central console or using the prism_central API. + properties: + name: + description: name is the resource name in the PC. + It cannot be empty if the type is Name. + type: string + type: + description: type is the identifier type to use + for this resource. + enum: + - UUID + - Name + type: string + uuid: + description: uuid is the UUID of the resource in + the PC. It cannot be empty if the type is UUID. + type: string + required: + - type + type: object + x-kubernetes-validations: + - message: uuid configuration is required when type + is UUID, and forbidden otherwise + rule: 'has(self.type) && self.type == ''UUID'' ? has(self.uuid) + : !has(self.uuid)' + - message: name configuration is required when type + is Name, and forbidden otherwise + rule: 'has(self.type) && self.type == ''Name'' ? has(self.name) + : !has(self.name)' + name: + description: |- + name defines the unique name of a failure domain. + Name is required and must be at most 64 characters in length. + It must consist of only lower case alphanumeric characters and hyphens (-). + It must start and end with an alphanumeric character. + This value is arbitrary and is used to identify the failure domain within the platform. + maxLength: 64 + minLength: 1 + pattern: '[a-z0-9]([-a-z0-9]*[a-z0-9])?' + type: string + subnets: + description: |- + subnets holds a list of identifiers (one or more) of the cluster's network subnets + for the Machine's VM to connect to. The subnet identifiers (uuid or name) can be + obtained from the Prism Central console or using the prism_central API. + items: + description: NutanixResourceIdentifier holds the identity + of a Nutanix PC resource (cluster, image, subnet, + etc.) + properties: + name: + description: name is the resource name in the + PC. It cannot be empty if the type is Name. + type: string + type: + description: type is the identifier type to use + for this resource. + enum: + - UUID + - Name + type: string + uuid: + description: uuid is the UUID of the resource + in the PC. It cannot be empty if the type is + UUID. + type: string + required: + - type + type: object + x-kubernetes-validations: + - message: uuid configuration is required when type + is UUID, and forbidden otherwise + rule: 'has(self.type) && self.type == ''UUID'' ? has(self.uuid) + : !has(self.uuid)' + - message: name configuration is required when type + is Name, and forbidden otherwise + rule: 'has(self.type) && self.type == ''Name'' ? has(self.name) + : !has(self.name)' + maxItems: 1 + minItems: 1 + type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map + required: + - cluster + - name + - subnets + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + prismCentral: + description: |- + prismCentral holds the endpoint address and port to access the Nutanix Prism Central. + When a cluster-wide proxy is installed, by default, this endpoint will be accessed via the proxy. + Should you wish for communication with this endpoint not to be proxied, please add the endpoint to the + proxy spec.noProxy list. + properties: + address: + description: address is the endpoint address (DNS name + or IP address) of the Nutanix Prism Central or Element + (cluster) + maxLength: 256 + type: string + port: + description: port is the port number to access the Nutanix + Prism Central or Element (cluster) + format: int32 + maximum: 65535 + minimum: 1 + type: integer + required: + - address + - port + type: object + prismElements: + description: |- + prismElements holds one or more endpoint address and port data to access the Nutanix + Prism Elements (clusters) of the Nutanix Prism Central. Currently we only support one + Prism Element (cluster) for an OpenShift cluster, where all the Nutanix resources (VMs, subnets, volumes, etc.) + used in the OpenShift cluster are located. In the future, we may support Nutanix resources (VMs, etc.) + spread over multiple Prism Elements (clusters) of the Prism Central. + items: + description: NutanixPrismElementEndpoint holds the name + and endpoint data for a Prism Element (cluster) + properties: + endpoint: + description: |- + endpoint holds the endpoint address and port data of the Prism Element (cluster). + When a cluster-wide proxy is installed, by default, this endpoint will be accessed via the proxy. + Should you wish for communication with this endpoint not to be proxied, please add the endpoint to the + proxy spec.noProxy list. + properties: + address: + description: address is the endpoint address (DNS + name or IP address) of the Nutanix Prism Central + or Element (cluster) + maxLength: 256 + type: string + port: + description: port is the port number to access the + Nutanix Prism Central or Element (cluster) + format: int32 + maximum: 65535 + minimum: 1 + type: integer + required: + - address + - port + type: object + name: + description: |- + name is the name of the Prism Element (cluster). This value will correspond with + the cluster field configured on other resources (eg Machines, PVCs, etc). + maxLength: 256 + type: string + required: + - endpoint + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + required: + - prismCentral + - prismElements + type: object + openstack: + description: OpenStack contains settings specific to the OpenStack + infrastructure provider. + properties: + apiServerInternalIPs: + description: |- + apiServerInternalIPs are the IP addresses to contact the Kubernetes API + server that can be used by components inside the cluster, like kubelets + using the infrastructure rather than Kubernetes networking. These are the + IPs for a self-hosted load balancer in front of the API servers. + In dual stack clusters this list contains two IP addresses, one from IPv4 + family and one from IPv6. + In single stack clusters a single IP address is expected. + When omitted, values from the status.apiServerInternalIPs will be used. + Once set, the list cannot be completely removed (but its second entry can). + items: + description: IP is an IP address (for example, "10.0.0.0" + or "fd00::"). + maxLength: 39 + minLength: 1 + type: string + x-kubernetes-validations: + - message: value must be a valid IP address + rule: isIP(self) + maxItems: 2 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - message: apiServerInternalIPs must contain at most one IPv4 + address and at most one IPv6 address + rule: 'size(self) == 2 && isIP(self[0]) && isIP(self[1]) + ? ip(self[0]).family() != ip(self[1]).family() : true' + ingressIPs: + description: |- + ingressIPs are the external IPs which route to the default ingress + controller. The IPs are suitable targets of a wildcard DNS record used to + resolve default route host names. + In dual stack clusters this list contains two IP addresses, one from IPv4 + family and one from IPv6. + In single stack clusters a single IP address is expected. + When omitted, values from the status.ingressIPs will be used. + Once set, the list cannot be completely removed (but its second entry can). + items: + description: IP is an IP address (for example, "10.0.0.0" + or "fd00::"). + maxLength: 39 + minLength: 1 + type: string + x-kubernetes-validations: + - message: value must be a valid IP address + rule: isIP(self) + maxItems: 2 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - message: ingressIPs must contain at most one IPv4 address + and at most one IPv6 address + rule: 'size(self) == 2 && isIP(self[0]) && isIP(self[1]) + ? ip(self[0]).family() != ip(self[1]).family() : true' + machineNetworks: + description: |- + machineNetworks are IP networks used to connect all the OpenShift cluster + nodes. Each network is provided in the CIDR format and should be IPv4 or IPv6, + for example "10.0.0.0/8" or "fd00::/8". + items: + description: CIDR is an IP address range in CIDR notation + (for example, "10.0.0.0/8" or "fd00::/8"). + maxLength: 43 + minLength: 1 + type: string + x-kubernetes-validations: + - message: value must be a valid CIDR network address + rule: isCIDR(self) + maxItems: 32 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - rule: self.all(x, self.exists_one(y, x == y)) + type: object + x-kubernetes-validations: + - message: apiServerInternalIPs list is required once set + rule: '!has(oldSelf.apiServerInternalIPs) || has(self.apiServerInternalIPs)' + - message: ingressIPs list is required once set + rule: '!has(oldSelf.ingressIPs) || has(self.ingressIPs)' + ovirt: + description: Ovirt contains settings specific to the oVirt infrastructure + provider. + type: object + powervs: + description: PowerVS contains settings specific to the IBM Power + Systems Virtual Servers infrastructure provider. + properties: + serviceEndpoints: + description: |- + serviceEndpoints is a list of custom endpoints which will override the default + service endpoints of a Power VS service. + items: + description: |- + PowervsServiceEndpoint stores the configuration of a custom url to + override existing defaults of PowerVS Services. + properties: + name: + description: |- + name is the name of the Power VS service. + Few of the services are + IAM - https://cloud.ibm.com/apidocs/iam-identity-token-api + ResourceController - https://cloud.ibm.com/apidocs/resource-controller/resource-controller + Power Cloud - https://cloud.ibm.com/apidocs/power-cloud + pattern: ^[a-z0-9-]+$ + type: string + url: + description: |- + url is fully qualified URI with scheme https, that overrides the default generated + endpoint for a client. + This must be provided and cannot be empty. + format: uri + pattern: ^https:// + type: string + required: + - name + - url + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + type: object + type: + description: |- + type is the underlying infrastructure provider for the cluster. This + value controls whether infrastructure automation such as service load + balancers, dynamic volume provisioning, machine creation and deletion, and + other integrations are enabled. If None, no infrastructure automation is + enabled. Allowed values are "AWS", "Azure", "BareMetal", "GCP", "Libvirt", + "OpenStack", "VSphere", "oVirt", "KubeVirt", "EquinixMetal", "PowerVS", + "AlibabaCloud", "Nutanix" and "None". Individual components may not support all platforms, + and must handle unrecognized platforms as None if they do not support that platform. + enum: + - "" + - AWS + - Azure + - BareMetal + - GCP + - Libvirt + - OpenStack + - None + - VSphere + - oVirt + - IBMCloud + - KubeVirt + - EquinixMetal + - PowerVS + - AlibabaCloud + - Nutanix + - External + type: string + vsphere: + description: VSphere contains settings specific to the VSphere + infrastructure provider. + properties: + apiServerInternalIPs: + description: |- + apiServerInternalIPs are the IP addresses to contact the Kubernetes API + server that can be used by components inside the cluster, like kubelets + using the infrastructure rather than Kubernetes networking. These are the + IPs for a self-hosted load balancer in front of the API servers. + In dual stack clusters this list contains two IP addresses, one from IPv4 + family and one from IPv6. + In single stack clusters a single IP address is expected. + When omitted, values from the status.apiServerInternalIPs will be used. + Once set, the list cannot be completely removed (but its second entry can). + items: + description: IP is an IP address (for example, "10.0.0.0" + or "fd00::"). + maxLength: 39 + minLength: 1 + type: string + x-kubernetes-validations: + - message: value must be a valid IP address + rule: isIP(self) + maxItems: 2 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - message: apiServerInternalIPs must contain at most one IPv4 + address and at most one IPv6 address + rule: 'size(self) == 2 && isIP(self[0]) && isIP(self[1]) + ? ip(self[0]).family() != ip(self[1]).family() : true' + failureDomains: + description: |- + failureDomains contains the definition of region, zone and the vCenter topology. + If this is omitted failure domains (regions and zones) will not be used. + items: + description: VSpherePlatformFailureDomainSpec holds the + region and zone failure domain and the vCenter topology + of that failure domain. + properties: + name: + description: |- + name defines the arbitrary but unique name + of a failure domain. + maxLength: 256 + minLength: 1 + type: string + region: + description: |- + region defines the name of a region tag that will + be attached to a vCenter datacenter. The tag + category in vCenter must be named openshift-region. + maxLength: 80 + minLength: 1 + type: string + regionAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + enum: + - HostGroup + - ComputeCluster + - Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' + server: + description: server is the fully-qualified domain name + or the IP address of the vCenter server. + maxLength: 255 + minLength: 1 + type: string + topology: + description: Topology describes a given failure domain + using vSphere constructs + properties: + computeCluster: + description: |- + computeCluster the absolute path of the vCenter cluster + in which virtual machine will be located. + The absolute path is of the form //host/. + The maximum length of the path is 2048 characters. + maxLength: 2048 + pattern: ^/.*?/host/.*? + type: string + datacenter: + description: |- + datacenter is the name of vCenter datacenter in which virtual machines will be located. + The maximum length of the datacenter name is 80 characters. + maxLength: 80 + type: string + datastore: + description: |- + datastore is the absolute path of the datastore in which the + virtual machine is located. + The absolute path is of the form //datastore/ + The maximum length of the path is 2048 characters. + maxLength: 2048 + pattern: ^/.*?/datastore/.*? + type: string + folder: + description: |- + folder is the absolute path of the folder where + virtual machines are located. The absolute path + is of the form //vm/. + The maximum length of the path is 2048 characters. + maxLength: 2048 + pattern: ^/.*?/vm/.*? + type: string + networks: + description: |- + networks is the list of port group network names within this failure domain. + If feature gate VSphereMultiNetworks is enabled, up to 10 network adapters may be defined. + 10 is the maximum number of virtual network devices which may be attached to a VM as defined by: + https://configmax.esp.vmware.com/guest?vmwareproduct=vSphere&release=vSphere%208.0&categories=1-0 + The available networks (port groups) can be listed using + `govc ls 'network/*'` + Networks should be in the form of an absolute path: + //network/. + items: + type: string + minItems: 1 + type: array + x-kubernetes-list-type: atomic + resourcePool: + description: |- + resourcePool is the absolute path of the resource pool where virtual machines will be + created. The absolute path is of the form //host//Resources/. + The maximum length of the path is 2048 characters. + maxLength: 2048 + pattern: ^/.*?/host/.*?/Resources.* + type: string + required: + - computeCluster + - datacenter + - datastore + - networks + type: object + zone: + description: |- + zone defines the name of a zone tag that will + be attached to a vCenter cluster. The tag + category in vCenter must be named openshift-zone. + maxLength: 80 + minLength: 1 + type: string + zoneAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + enum: + - HostGroup + - ComputeCluster + - Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' + required: + - name + - region + - server + - topology + - zone + type: object + x-kubernetes-validations: + - message: when zoneAffinity type is HostGroup, regionAffinity + type must be ComputeCluster + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''HostGroup'' ? has(self.regionAffinity) && self.regionAffinity.type + == ''ComputeCluster'' : true' + - message: when zoneAffinity type is ComputeCluster, regionAffinity + type must be Datacenter + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''ComputeCluster'' ? has(self.regionAffinity) && + self.regionAffinity.type == ''Datacenter'' : true' + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + ingressIPs: + description: |- + ingressIPs are the external IPs which route to the default ingress + controller. The IPs are suitable targets of a wildcard DNS record used to + resolve default route host names. + In dual stack clusters this list contains two IP addresses, one from IPv4 + family and one from IPv6. + In single stack clusters a single IP address is expected. + When omitted, values from the status.ingressIPs will be used. + Once set, the list cannot be completely removed (but its second entry can). + items: + description: IP is an IP address (for example, "10.0.0.0" + or "fd00::"). + maxLength: 39 + minLength: 1 + type: string + x-kubernetes-validations: + - message: value must be a valid IP address + rule: isIP(self) + maxItems: 2 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - message: ingressIPs must contain at most one IPv4 address + and at most one IPv6 address + rule: 'size(self) == 2 && isIP(self[0]) && isIP(self[1]) + ? ip(self[0]).family() != ip(self[1]).family() : true' + machineNetworks: + description: |- + machineNetworks are IP networks used to connect all the OpenShift cluster + nodes. Each network is provided in the CIDR format and should be IPv4 or IPv6, + for example "10.0.0.0/8" or "fd00::/8". + items: + description: CIDR is an IP address range in CIDR notation + (for example, "10.0.0.0/8" or "fd00::/8"). + maxLength: 43 + minLength: 1 + type: string + x-kubernetes-validations: + - message: value must be a valid CIDR network address + rule: isCIDR(self) + maxItems: 32 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - rule: self.all(x, self.exists_one(y, x == y)) + nodeNetworking: + description: |- + nodeNetworking contains the definition of internal and external network constraints for + assigning the node's networking. + If this field is omitted, networking defaults to the legacy + address selection behavior which is to only support a single address and + return the first one found. + properties: + external: + description: external represents the network configuration + of the node that is externally routable. + properties: + excludeNetworkSubnetCidr: + description: |- + excludeNetworkSubnetCidr IP addresses in subnet ranges will be excluded when selecting + the IP address from the VirtualMachine's VM for use in the status.addresses fields. + items: + type: string + type: array + x-kubernetes-list-type: atomic + network: + description: |- + network VirtualMachine's VM Network names that will be used to when searching + for status.addresses fields. Note that if internal.networkSubnetCIDR and + external.networkSubnetCIDR are not set, then the vNIC associated to this network must + only have a single IP address assigned to it. + The available networks (port groups) can be listed using + `govc ls 'network/*'` + type: string + networkSubnetCidr: + description: |- + networkSubnetCidr IP address on VirtualMachine's network interfaces included in the fields' CIDRs + that will be used in respective status.addresses fields. + items: + type: string + type: array + x-kubernetes-list-type: set + type: object + internal: + description: internal represents the network configuration + of the node that is routable only within the cluster. + properties: + excludeNetworkSubnetCidr: + description: |- + excludeNetworkSubnetCidr IP addresses in subnet ranges will be excluded when selecting + the IP address from the VirtualMachine's VM for use in the status.addresses fields. + items: + type: string + type: array + x-kubernetes-list-type: atomic + network: + description: |- + network VirtualMachine's VM Network names that will be used to when searching + for status.addresses fields. Note that if internal.networkSubnetCIDR and + external.networkSubnetCIDR are not set, then the vNIC associated to this network must + only have a single IP address assigned to it. + The available networks (port groups) can be listed using + `govc ls 'network/*'` + type: string + networkSubnetCidr: + description: |- + networkSubnetCidr IP address on VirtualMachine's network interfaces included in the fields' CIDRs + that will be used in respective status.addresses fields. + items: + type: string + type: array + x-kubernetes-list-type: set + type: object + type: object + vcenters: + description: |- + vcenters holds the connection details for services to communicate with vCenter. + Currently, only a single vCenter is supported, but in tech preview 3 vCenters are supported. + Once the cluster has been installed, you are unable to change the current number of defined + vCenters except in the case where the cluster has been upgraded from a version of OpenShift + where the vsphere platform spec was not present. You may make modifications to the existing + vCenters that are defined in the vcenters list in order to match with any added or modified + failure domains. + items: + description: |- + VSpherePlatformVCenterSpec stores the vCenter connection fields. + This is used by the vSphere CCM. + properties: + datacenters: + description: |- + The vCenter Datacenters in which the RHCOS + vm guests are located. This field will + be used by the Cloud Controller Manager. + Each datacenter listed here should be used within + a topology. + items: + type: string + minItems: 1 + type: array + x-kubernetes-list-type: set + port: + description: |- + port is the TCP port that will be used to communicate to + the vCenter endpoint. + When omitted, this means the user has no opinion and + it is up to the platform to choose a sensible default, + which is subject to change over time. + format: int32 + maximum: 32767 + minimum: 1 + type: integer + server: + description: server is the fully-qualified domain name + or the IP address of the vCenter server. + maxLength: 255 + type: string + required: + - datacenters + - server + type: object + minItems: 0 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - message: vcenters cannot be added or removed once set + rule: 'size(self) != size(oldSelf) ? size(oldSelf) == 0 + && size(self) < 2 : true' + type: object + x-kubernetes-validations: + - message: apiServerInternalIPs list is required once set + rule: '!has(oldSelf.apiServerInternalIPs) || has(self.apiServerInternalIPs)' + - message: ingressIPs list is required once set + rule: '!has(oldSelf.ingressIPs) || has(self.ingressIPs)' + - message: vcenters can have at most 1 item when configured post-install + rule: '!has(oldSelf.vcenters) && has(self.vcenters) ? size(self.vcenters) + < 2 : true' + type: object + x-kubernetes-validations: + - message: vcenters can have at most 1 item when configured post-install + rule: '!has(oldSelf.vsphere) && has(self.vsphere) ? size(self.vsphere.vcenters) + < 2 : true' + type: object + status: + description: status holds observed values from the cluster. They may not + be overridden. + properties: + apiServerInternalURI: + description: |- + apiServerInternalURL is a valid URI with scheme 'https', + address and optionally a port (defaulting to 443). apiServerInternalURL can be used by components + like kubelets, to contact the Kubernetes API server using the + infrastructure provider rather than Kubernetes networking. + type: string + apiServerURL: + description: |- + apiServerURL is a valid URI with scheme 'https', address and + optionally a port (defaulting to 443). apiServerURL can be used by components like the web console + to tell users where to find the Kubernetes API. + type: string + controlPlaneTopology: + default: HighlyAvailable + description: |- + controlPlaneTopology expresses the expectations for operands that normally run on control nodes. + The default is 'HighlyAvailable', which represents the behavior operators have in a "normal" cluster. + The 'SingleReplica' mode will be used in single-node deployments + and the operators should not configure the operand for highly-available operation + The 'External' mode indicates that the control plane is hosted externally to the cluster and that + its components are not visible within the cluster. + enum: + - HighlyAvailable + - SingleReplica + - External + type: string + cpuPartitioning: + default: None + description: |- + cpuPartitioning expresses if CPU partitioning is a currently enabled feature in the cluster. + CPU Partitioning means that this cluster can support partitioning workloads to specific CPU Sets. + Valid values are "None" and "AllNodes". When omitted, the default value is "None". + The default value of "None" indicates that no nodes will be setup with CPU partitioning. + The "AllNodes" value indicates that all nodes have been setup with CPU partitioning, + and can then be further configured via the PerformanceProfile API. + enum: + - None + - AllNodes + type: string + etcdDiscoveryDomain: + description: |- + etcdDiscoveryDomain is the domain used to fetch the SRV records for discovering + etcd servers and clients. + For more info: https://github.com/etcd-io/etcd/blob/329be66e8b3f9e2e6af83c123ff89297e49ebd15/Documentation/op-guide/clustering.md#dns-discovery + deprecated: as of 4.7, this field is no longer set or honored. It will be removed in a future release. + type: string + infrastructureName: + description: |- + infrastructureName uniquely identifies a cluster with a human friendly name. + Once set it should not be changed. Must be of max length 27 and must have only + alphanumeric or hyphen characters. + type: string + infrastructureTopology: + default: HighlyAvailable + description: |- + infrastructureTopology expresses the expectations for infrastructure services that do not run on control + plane nodes, usually indicated by a node selector for a `role` value + other than `master`. + The default is 'HighlyAvailable', which represents the behavior operators have in a "normal" cluster. + The 'SingleReplica' mode will be used in single-node deployments + and the operators should not configure the operand for highly-available operation + NOTE: External topology mode is not applicable for this field. + enum: + - HighlyAvailable + - SingleReplica + type: string + platform: + description: |- + platform is the underlying infrastructure provider for the cluster. + + Deprecated: Use platformStatus.type instead. + enum: + - "" + - AWS + - Azure + - BareMetal + - GCP + - Libvirt + - OpenStack + - None + - VSphere + - oVirt + - IBMCloud + - KubeVirt + - EquinixMetal + - PowerVS + - AlibabaCloud + - Nutanix + - External + type: string + platformStatus: + description: |- + platformStatus holds status information specific to the underlying + infrastructure provider. + properties: + alibabaCloud: + description: AlibabaCloud contains settings specific to the Alibaba + Cloud infrastructure provider. + properties: + region: + description: region specifies the region for Alibaba Cloud + resources created for the cluster. + pattern: ^[0-9A-Za-z-]+$ + type: string + resourceGroupID: + description: resourceGroupID is the ID of the resource group + for the cluster. + pattern: ^(rg-[0-9A-Za-z]+)?$ + type: string + resourceTags: + description: resourceTags is a list of additional tags to + apply to Alibaba Cloud resources created for the cluster. + items: + description: AlibabaCloudResourceTag is the set of tags + to add to apply to resources. + properties: + key: + description: key is the key of the tag. + maxLength: 128 + minLength: 1 + type: string + value: + description: value is the value of the tag. + maxLength: 128 + minLength: 1 + type: string + required: + - key + - value + type: object + maxItems: 20 + type: array + x-kubernetes-list-map-keys: + - key + x-kubernetes-list-type: map + required: + - region + type: object + aws: + description: AWS contains settings specific to the Amazon Web + Services infrastructure provider. + properties: + region: + description: region holds the default AWS region for new AWS + resources created by the cluster. + type: string + resourceTags: + description: |- + resourceTags is a list of additional tags to apply to AWS resources created for the cluster. + See https://docs.aws.amazon.com/general/latest/gr/aws_tagging.html for information on tagging AWS resources. + AWS supports a maximum of 50 tags per resource. OpenShift reserves 25 tags for its use, leaving 25 tags + available for the user. + items: + description: AWSResourceTag is a tag to apply to AWS resources + created for the cluster. + properties: + key: + description: key is the key of the tag + maxLength: 128 + minLength: 1 + pattern: ^[0-9A-Za-z_.:/=+-@]+$ + type: string + value: + description: |- + value is the value of the tag. + Some AWS service do not support empty values. Since tags are added to resources in many services, the + length of the tag value must meet the requirements of all services. + maxLength: 256 + minLength: 1 + pattern: ^[0-9A-Za-z_.:/=+-@]+$ + type: string + required: + - key + - value + type: object + maxItems: 25 + type: array + x-kubernetes-list-type: atomic + serviceEndpoints: + description: |- + ServiceEndpoints list contains custom endpoints which will override default + service endpoint of AWS Services. + There must be only one ServiceEndpoint for a service. + items: + description: |- + AWSServiceEndpoint store the configuration of a custom url to + override existing defaults of AWS Services. + properties: + name: + description: |- + name is the name of the AWS service. + The list of all the service names can be found at https://docs.aws.amazon.com/general/latest/gr/aws-service-information.html + This must be provided and cannot be empty. + pattern: ^[a-z0-9-]+$ + type: string + url: + description: |- + url is fully qualified URI with scheme https, that overrides the default generated + endpoint for a client. + This must be provided and cannot be empty. + pattern: ^https:// + type: string + type: object + type: array + x-kubernetes-list-type: atomic + type: object + azure: + description: Azure contains settings specific to the Azure infrastructure + provider. + properties: + armEndpoint: + description: armEndpoint specifies a URL to use for resource + management in non-soverign clouds such as Azure Stack. + type: string + cloudName: + description: |- + cloudName is the name of the Azure cloud environment which can be used to configure the Azure SDK + with the appropriate Azure API endpoints. + If empty, the value is equal to `AzurePublicCloud`. + enum: + - "" + - AzurePublicCloud + - AzureUSGovernmentCloud + - AzureChinaCloud + - AzureGermanCloud + - AzureStackCloud + type: string + networkResourceGroupName: + description: |- + networkResourceGroupName is the Resource Group for network resources like the Virtual Network and Subnets used by the cluster. + If empty, the value is same as ResourceGroupName. + type: string + resourceGroupName: + description: resourceGroupName is the Resource Group for new + Azure resources created for the cluster. + type: string + resourceTags: + description: |- + resourceTags is a list of additional tags to apply to Azure resources created for the cluster. + See https://docs.microsoft.com/en-us/rest/api/resources/tags for information on tagging Azure resources. + Due to limitations on Automation, Content Delivery Network, DNS Azure resources, a maximum of 15 tags + may be applied. OpenShift reserves 5 tags for internal use, allowing 10 tags for user configuration. + items: + description: AzureResourceTag is a tag to apply to Azure + resources created for the cluster. + properties: + key: + description: |- + key is the key part of the tag. A tag key can have a maximum of 128 characters and cannot be empty. Key + must begin with a letter, end with a letter, number or underscore, and must contain only alphanumeric + characters and the following special characters `_ . -`. + maxLength: 128 + minLength: 1 + pattern: ^[a-zA-Z]([0-9A-Za-z_.-]*[0-9A-Za-z_])?$ + type: string + value: + description: |- + value is the value part of the tag. A tag value can have a maximum of 256 characters and cannot be empty. Value + must contain only alphanumeric characters and the following special characters `_ + , - . / : ; < = > ? @`. + maxLength: 256 + minLength: 1 + pattern: ^[0-9A-Za-z_.=+-@]+$ + type: string + required: + - key + - value + type: object + maxItems: 10 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - message: resourceTags are immutable and may only be configured + during installation + rule: self.all(x, x in oldSelf) && oldSelf.all(x, x in self) + type: object + x-kubernetes-validations: + - message: resourceTags may only be configured during installation + rule: '!has(oldSelf.resourceTags) && !has(self.resourceTags) + || has(oldSelf.resourceTags) && has(self.resourceTags)' + baremetal: + description: BareMetal contains settings specific to the BareMetal + platform. + properties: + apiServerInternalIP: + description: |- + apiServerInternalIP is an IP address to contact the Kubernetes API server that can be used + by components inside the cluster, like kubelets using the infrastructure rather + than Kubernetes networking. It is the IP that the Infrastructure.status.apiServerInternalURI + points to. It is the IP for a self-hosted load balancer in front of the API servers. + + Deprecated: Use APIServerInternalIPs instead. + type: string + apiServerInternalIPs: + description: |- + apiServerInternalIPs are the IP addresses to contact the Kubernetes API + server that can be used by components inside the cluster, like kubelets + using the infrastructure rather than Kubernetes networking. These are the + IPs for a self-hosted load balancer in front of the API servers. In dual + stack clusters this list contains two IPs otherwise only one. + format: ip + items: + type: string + maxItems: 2 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - message: apiServerInternalIPs must contain at most one IPv4 + address and at most one IPv6 address + rule: 'self == oldSelf || (size(self) == 2 && isIP(self[0]) + && isIP(self[1]) ? ip(self[0]).family() != ip(self[1]).family() + : true)' + ingressIP: + description: |- + ingressIP is an external IP which routes to the default ingress controller. + The IP is a suitable target of a wildcard DNS record used to resolve default route host names. + + Deprecated: Use IngressIPs instead. + type: string + ingressIPs: + description: |- + ingressIPs are the external IPs which route to the default ingress + controller. The IPs are suitable targets of a wildcard DNS record used to + resolve default route host names. In dual stack clusters this list + contains two IPs otherwise only one. + format: ip + items: + type: string + maxItems: 2 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - message: ingressIPs must contain at most one IPv4 address + and at most one IPv6 address + rule: 'self == oldSelf || (size(self) == 2 && isIP(self[0]) + && isIP(self[1]) ? ip(self[0]).family() != ip(self[1]).family() + : true)' + machineNetworks: + description: machineNetworks are IP networks used to connect + all the OpenShift cluster nodes. + items: + description: CIDR is an IP address range in CIDR notation + (for example, "10.0.0.0/8" or "fd00::/8"). + maxLength: 43 + minLength: 1 + type: string + x-kubernetes-validations: + - message: value must be a valid CIDR network address + rule: isCIDR(self) + maxItems: 32 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - rule: self.all(x, self.exists_one(y, x == y)) + nodeDNSIP: + description: |- + nodeDNSIP is the IP address for the internal DNS used by the + nodes. Unlike the one managed by the DNS operator, `NodeDNSIP` + provides name resolution for the nodes themselves. There is no DNS-as-a-service for + BareMetal deployments. In order to minimize necessary changes to the + datacenter DNS, a DNS service is hosted as a static pod to serve those hostnames + to the nodes in the cluster. + type: string + type: object + equinixMetal: + description: EquinixMetal contains settings specific to the Equinix + Metal infrastructure provider. + properties: + apiServerInternalIP: + description: |- + apiServerInternalIP is an IP address to contact the Kubernetes API server that can be used + by components inside the cluster, like kubelets using the infrastructure rather + than Kubernetes networking. It is the IP that the Infrastructure.status.apiServerInternalURI + points to. It is the IP for a self-hosted load balancer in front of the API servers. + type: string + ingressIP: + description: |- + ingressIP is an external IP which routes to the default ingress controller. + The IP is a suitable target of a wildcard DNS record used to resolve default route host names. + type: string + type: object + external: + description: External contains settings specific to the generic + External infrastructure provider. + properties: + cloudControllerManager: + description: |- + cloudControllerManager contains settings specific to the external Cloud Controller Manager (a.k.a. CCM or CPI). + When omitted, new nodes will be not tainted + and no extra initialization from the cloud controller manager is expected. + properties: + state: + description: |- + state determines whether or not an external Cloud Controller Manager is expected to + be installed within the cluster. + https://kubernetes.io/docs/tasks/administer-cluster/running-cloud-controller/#running-cloud-controller-manager + + Valid values are "External", "None" and omitted. + When set to "External", new nodes will be tainted as uninitialized when created, + preventing them from running workloads until they are initialized by the cloud controller manager. + When omitted or set to "None", new nodes will be not tainted + and no extra initialization from the cloud controller manager is expected. + enum: + - "" + - External + - None + type: string + x-kubernetes-validations: + - message: state is immutable once set + rule: self == oldSelf + type: object + x-kubernetes-validations: + - message: state may not be added or removed once set + rule: (has(self.state) == has(oldSelf.state)) || (!has(oldSelf.state) + && self.state != "External") + type: object + x-kubernetes-validations: + - message: cloudControllerManager may not be added or removed + once set + rule: has(self.cloudControllerManager) == has(oldSelf.cloudControllerManager) + gcp: + description: GCP contains settings specific to the Google Cloud + Platform infrastructure provider. + properties: + projectID: + description: resourceGroupName is the Project ID for new GCP + resources created for the cluster. + type: string + region: + description: region holds the region for new GCP resources + created for the cluster. + type: string + type: object + ibmcloud: + description: IBMCloud contains settings specific to the IBMCloud + infrastructure provider. + properties: + cisInstanceCRN: + description: |- + CISInstanceCRN is the CRN of the Cloud Internet Services instance managing + the DNS zone for the cluster's base domain + type: string + dnsInstanceCRN: + description: |- + DNSInstanceCRN is the CRN of the DNS Services instance managing the DNS zone + for the cluster's base domain + type: string + location: + description: Location is where the cluster has been deployed + type: string + providerType: + description: ProviderType indicates the type of cluster that + was created + type: string + resourceGroupName: + description: ResourceGroupName is the Resource Group for new + IBMCloud resources created for the cluster. + type: string + serviceEndpoints: + description: |- + serviceEndpoints is a list of custom endpoints which will override the default + service endpoints of an IBM Cloud service. These endpoints are consumed by + components within the cluster to reach the respective IBM Cloud Services. + items: + description: |- + IBMCloudServiceEndpoint stores the configuration of a custom url to + override existing defaults of IBM Cloud Services. + properties: + name: + description: |- + name is the name of the IBM Cloud service. + Possible values are: CIS, COS, COSConfig, DNSServices, GlobalCatalog, GlobalSearch, GlobalTagging, HyperProtect, IAM, KeyProtect, ResourceController, ResourceManager, or VPC. + For example, the IBM Cloud Private IAM service could be configured with the + service `name` of `IAM` and `url` of `https://private.iam.cloud.ibm.com` + Whereas the IBM Cloud Private VPC service for US South (Dallas) could be configured + with the service `name` of `VPC` and `url` of `https://us.south.private.iaas.cloud.ibm.com` + enum: + - CIS + - COS + - COSConfig + - DNSServices + - GlobalCatalog + - GlobalSearch + - GlobalTagging + - HyperProtect + - IAM + - KeyProtect + - ResourceController + - ResourceManager + - VPC + type: string + url: + description: |- + url is fully qualified URI with scheme https, that overrides the default generated + endpoint for a client. + This must be provided and cannot be empty. + type: string + x-kubernetes-validations: + - message: url must be a valid absolute URL + rule: isURL(self) + required: + - name + - url + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + type: object + kubevirt: + description: Kubevirt contains settings specific to the kubevirt + infrastructure provider. + properties: + apiServerInternalIP: + description: |- + apiServerInternalIP is an IP address to contact the Kubernetes API server that can be used + by components inside the cluster, like kubelets using the infrastructure rather + than Kubernetes networking. It is the IP that the Infrastructure.status.apiServerInternalURI + points to. It is the IP for a self-hosted load balancer in front of the API servers. + type: string + ingressIP: + description: |- + ingressIP is an external IP which routes to the default ingress controller. + The IP is a suitable target of a wildcard DNS record used to resolve default route host names. + type: string + type: object + nutanix: + description: Nutanix contains settings specific to the Nutanix + infrastructure provider. + properties: + apiServerInternalIP: + description: |- + apiServerInternalIP is an IP address to contact the Kubernetes API server that can be used + by components inside the cluster, like kubelets using the infrastructure rather + than Kubernetes networking. It is the IP that the Infrastructure.status.apiServerInternalURI + points to. It is the IP for a self-hosted load balancer in front of the API servers. + + Deprecated: Use APIServerInternalIPs instead. + type: string + apiServerInternalIPs: + description: |- + apiServerInternalIPs are the IP addresses to contact the Kubernetes API + server that can be used by components inside the cluster, like kubelets + using the infrastructure rather than Kubernetes networking. These are the + IPs for a self-hosted load balancer in front of the API servers. In dual + stack clusters this list contains two IPs otherwise only one. + format: ip + items: + type: string + maxItems: 2 + type: array + x-kubernetes-list-type: set + x-kubernetes-validations: + - message: apiServerInternalIPs must contain at most one IPv4 + address and at most one IPv6 address + rule: 'self == oldSelf || (size(self) == 2 && isIP(self[0]) + && isIP(self[1]) ? ip(self[0]).family() != ip(self[1]).family() + : true)' + ingressIP: + description: |- + ingressIP is an external IP which routes to the default ingress controller. + The IP is a suitable target of a wildcard DNS record used to resolve default route host names. + + Deprecated: Use IngressIPs instead. + type: string + ingressIPs: + description: |- + ingressIPs are the external IPs which route to the default ingress + controller. The IPs are suitable targets of a wildcard DNS record used to + resolve default route host names. In dual stack clusters this list + contains two IPs otherwise only one. + format: ip + items: + type: string + maxItems: 2 + type: array + x-kubernetes-list-type: set + x-kubernetes-validations: + - message: ingressIPs must contain at most one IPv4 address + and at most one IPv6 address + rule: 'self == oldSelf || (size(self) == 2 && isIP(self[0]) + && isIP(self[1]) ? ip(self[0]).family() != ip(self[1]).family() + : true)' + type: object + openstack: + description: OpenStack contains settings specific to the OpenStack + infrastructure provider. + properties: + apiServerInternalIP: + description: |- + apiServerInternalIP is an IP address to contact the Kubernetes API server that can be used + by components inside the cluster, like kubelets using the infrastructure rather + than Kubernetes networking. It is the IP that the Infrastructure.status.apiServerInternalURI + points to. It is the IP for a self-hosted load balancer in front of the API servers. + + Deprecated: Use APIServerInternalIPs instead. + type: string + apiServerInternalIPs: + description: |- + apiServerInternalIPs are the IP addresses to contact the Kubernetes API + server that can be used by components inside the cluster, like kubelets + using the infrastructure rather than Kubernetes networking. These are the + IPs for a self-hosted load balancer in front of the API servers. In dual + stack clusters this list contains two IPs otherwise only one. + format: ip + items: + type: string + maxItems: 2 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - message: apiServerInternalIPs must contain at most one IPv4 + address and at most one IPv6 address + rule: 'self == oldSelf || (size(self) == 2 && isIP(self[0]) + && isIP(self[1]) ? ip(self[0]).family() != ip(self[1]).family() + : true)' + cloudName: + description: |- + cloudName is the name of the desired OpenStack cloud in the + client configuration file (`clouds.yaml`). + type: string + ingressIP: + description: |- + ingressIP is an external IP which routes to the default ingress controller. + The IP is a suitable target of a wildcard DNS record used to resolve default route host names. + + Deprecated: Use IngressIPs instead. + type: string + ingressIPs: + description: |- + ingressIPs are the external IPs which route to the default ingress + controller. The IPs are suitable targets of a wildcard DNS record used to + resolve default route host names. In dual stack clusters this list + contains two IPs otherwise only one. + format: ip + items: + type: string + maxItems: 2 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - message: ingressIPs must contain at most one IPv4 address + and at most one IPv6 address + rule: 'self == oldSelf || (size(self) == 2 && isIP(self[0]) + && isIP(self[1]) ? ip(self[0]).family() != ip(self[1]).family() + : true)' + loadBalancer: + default: + type: OpenShiftManagedDefault + description: loadBalancer defines how the load balancer used + by the cluster is configured. + properties: + type: + default: OpenShiftManagedDefault + description: |- + type defines the type of load balancer used by the cluster on OpenStack platform + which can be a user-managed or openshift-managed load balancer + that is to be used for the OpenShift API and Ingress endpoints. + When set to OpenShiftManagedDefault the static pods in charge of API and Ingress traffic load-balancing + defined in the machine config operator will be deployed. + When set to UserManaged these static pods will not be deployed and it is expected that + the load balancer is configured out of band by the deployer. + When omitted, this means no opinion and the platform is left to choose a reasonable default. + The default value is OpenShiftManagedDefault. + enum: + - OpenShiftManagedDefault + - UserManaged + type: string + x-kubernetes-validations: + - message: type is immutable once set + rule: oldSelf == '' || self == oldSelf + type: object + machineNetworks: + description: machineNetworks are IP networks used to connect + all the OpenShift cluster nodes. + items: + description: CIDR is an IP address range in CIDR notation + (for example, "10.0.0.0/8" or "fd00::/8"). + maxLength: 43 + minLength: 1 + type: string + x-kubernetes-validations: + - message: value must be a valid CIDR network address + rule: isCIDR(self) + maxItems: 32 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - rule: self.all(x, self.exists_one(y, x == y)) + nodeDNSIP: + description: |- + nodeDNSIP is the IP address for the internal DNS used by the + nodes. Unlike the one managed by the DNS operator, `NodeDNSIP` + provides name resolution for the nodes themselves. There is no DNS-as-a-service for + OpenStack deployments. In order to minimize necessary changes to the + datacenter DNS, a DNS service is hosted as a static pod to serve those hostnames + to the nodes in the cluster. + type: string + type: object + ovirt: + description: Ovirt contains settings specific to the oVirt infrastructure + provider. + properties: + apiServerInternalIP: + description: |- + apiServerInternalIP is an IP address to contact the Kubernetes API server that can be used + by components inside the cluster, like kubelets using the infrastructure rather + than Kubernetes networking. It is the IP that the Infrastructure.status.apiServerInternalURI + points to. It is the IP for a self-hosted load balancer in front of the API servers. + + Deprecated: Use APIServerInternalIPs instead. + type: string + apiServerInternalIPs: + description: |- + apiServerInternalIPs are the IP addresses to contact the Kubernetes API + server that can be used by components inside the cluster, like kubelets + using the infrastructure rather than Kubernetes networking. These are the + IPs for a self-hosted load balancer in front of the API servers. In dual + stack clusters this list contains two IPs otherwise only one. + format: ip + items: + type: string + maxItems: 2 + type: array + x-kubernetes-list-type: set + x-kubernetes-validations: + - message: apiServerInternalIPs must contain at most one IPv4 + address and at most one IPv6 address + rule: 'self == oldSelf || (size(self) == 2 && isIP(self[0]) + && isIP(self[1]) ? ip(self[0]).family() != ip(self[1]).family() + : true)' + ingressIP: + description: |- + ingressIP is an external IP which routes to the default ingress controller. + The IP is a suitable target of a wildcard DNS record used to resolve default route host names. + + Deprecated: Use IngressIPs instead. + type: string + ingressIPs: + description: |- + ingressIPs are the external IPs which route to the default ingress + controller. The IPs are suitable targets of a wildcard DNS record used to + resolve default route host names. In dual stack clusters this list + contains two IPs otherwise only one. + format: ip + items: + type: string + maxItems: 2 + type: array + x-kubernetes-list-type: set + x-kubernetes-validations: + - message: ingressIPs must contain at most one IPv4 address + and at most one IPv6 address + rule: 'self == oldSelf || (size(self) == 2 && isIP(self[0]) + && isIP(self[1]) ? ip(self[0]).family() != ip(self[1]).family() + : true)' + nodeDNSIP: + description: 'deprecated: as of 4.6, this field is no longer + set or honored. It will be removed in a future release.' + type: string + type: object + powervs: + description: PowerVS contains settings specific to the Power Systems + Virtual Servers infrastructure provider. + properties: + cisInstanceCRN: + description: |- + CISInstanceCRN is the CRN of the Cloud Internet Services instance managing + the DNS zone for the cluster's base domain + type: string + dnsInstanceCRN: + description: |- + DNSInstanceCRN is the CRN of the DNS Services instance managing the DNS zone + for the cluster's base domain + type: string + region: + description: region holds the default Power VS region for + new Power VS resources created by the cluster. + type: string + resourceGroup: + description: |- + resourceGroup is the resource group name for new IBMCloud resources created for a cluster. + The resource group specified here will be used by cluster-image-registry-operator to set up a COS Instance in IBMCloud for the cluster registry. + More about resource groups can be found here: https://cloud.ibm.com/docs/account?topic=account-rgs. + When omitted, the image registry operator won't be able to configure storage, + which results in the image registry cluster operator not being in an available state. + maxLength: 40 + pattern: ^[a-zA-Z0-9-_ ]+$ + type: string + x-kubernetes-validations: + - message: resourceGroup is immutable once set + rule: oldSelf == '' || self == oldSelf + serviceEndpoints: + description: |- + serviceEndpoints is a list of custom endpoints which will override the default + service endpoints of a Power VS service. + items: + description: |- + PowervsServiceEndpoint stores the configuration of a custom url to + override existing defaults of PowerVS Services. + properties: + name: + description: |- + name is the name of the Power VS service. + Few of the services are + IAM - https://cloud.ibm.com/apidocs/iam-identity-token-api + ResourceController - https://cloud.ibm.com/apidocs/resource-controller/resource-controller + Power Cloud - https://cloud.ibm.com/apidocs/power-cloud + pattern: ^[a-z0-9-]+$ + type: string + url: + description: |- + url is fully qualified URI with scheme https, that overrides the default generated + endpoint for a client. + This must be provided and cannot be empty. + format: uri + pattern: ^https:// + type: string + required: + - name + - url + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + zone: + description: |- + zone holds the default zone for the new Power VS resources created by the cluster. + Note: Currently only single-zone OCP clusters are supported + type: string + type: object + x-kubernetes-validations: + - message: cannot unset resourceGroup once set + rule: '!has(oldSelf.resourceGroup) || has(self.resourceGroup)' + type: + description: |- + type is the underlying infrastructure provider for the cluster. This + value controls whether infrastructure automation such as service load + balancers, dynamic volume provisioning, machine creation and deletion, and + other integrations are enabled. If None, no infrastructure automation is + enabled. Allowed values are "AWS", "Azure", "BareMetal", "GCP", "Libvirt", + "OpenStack", "VSphere", "oVirt", "EquinixMetal", "PowerVS", "AlibabaCloud", "Nutanix" and "None". + Individual components may not support all platforms, and must handle + unrecognized platforms as None if they do not support that platform. + + This value will be synced with to the `status.platform` and `status.platformStatus.type`. + Currently this value cannot be changed once set. + enum: + - "" + - AWS + - Azure + - BareMetal + - GCP + - Libvirt + - OpenStack + - None + - VSphere + - oVirt + - IBMCloud + - KubeVirt + - EquinixMetal + - PowerVS + - AlibabaCloud + - Nutanix + - External + type: string + vsphere: + description: VSphere contains settings specific to the VSphere + infrastructure provider. + properties: + apiServerInternalIP: + description: |- + apiServerInternalIP is an IP address to contact the Kubernetes API server that can be used + by components inside the cluster, like kubelets using the infrastructure rather + than Kubernetes networking. It is the IP that the Infrastructure.status.apiServerInternalURI + points to. It is the IP for a self-hosted load balancer in front of the API servers. + + Deprecated: Use APIServerInternalIPs instead. + type: string + apiServerInternalIPs: + description: |- + apiServerInternalIPs are the IP addresses to contact the Kubernetes API + server that can be used by components inside the cluster, like kubelets + using the infrastructure rather than Kubernetes networking. These are the + IPs for a self-hosted load balancer in front of the API servers. In dual + stack clusters this list contains two IPs otherwise only one. + format: ip + items: + type: string + maxItems: 2 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - message: apiServerInternalIPs must contain at most one IPv4 + address and at most one IPv6 address + rule: 'self == oldSelf || (size(self) == 2 && isIP(self[0]) + && isIP(self[1]) ? ip(self[0]).family() != ip(self[1]).family() + : true)' + ingressIP: + description: |- + ingressIP is an external IP which routes to the default ingress controller. + The IP is a suitable target of a wildcard DNS record used to resolve default route host names. + + Deprecated: Use IngressIPs instead. + type: string + ingressIPs: + description: |- + ingressIPs are the external IPs which route to the default ingress + controller. The IPs are suitable targets of a wildcard DNS record used to + resolve default route host names. In dual stack clusters this list + contains two IPs otherwise only one. + format: ip + items: + type: string + maxItems: 2 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - message: ingressIPs must contain at most one IPv4 address + and at most one IPv6 address + rule: 'self == oldSelf || (size(self) == 2 && isIP(self[0]) + && isIP(self[1]) ? ip(self[0]).family() != ip(self[1]).family() + : true)' + machineNetworks: + description: machineNetworks are IP networks used to connect + all the OpenShift cluster nodes. + items: + description: CIDR is an IP address range in CIDR notation + (for example, "10.0.0.0/8" or "fd00::/8"). + maxLength: 43 + minLength: 1 + type: string + x-kubernetes-validations: + - message: value must be a valid CIDR network address + rule: isCIDR(self) + maxItems: 32 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - rule: self.all(x, self.exists_one(y, x == y)) + nodeDNSIP: + description: |- + nodeDNSIP is the IP address for the internal DNS used by the + nodes. Unlike the one managed by the DNS operator, `NodeDNSIP` + provides name resolution for the nodes themselves. There is no DNS-as-a-service for + vSphere deployments. In order to minimize necessary changes to the + datacenter DNS, a DNS service is hosted as a static pod to serve those hostnames + to the nodes in the cluster. + type: string + type: object + type: object + type: object + required: + - spec + type: object + served: true + storage: true + subresources: + status: {} diff --git a/config/v1/zz_generated.featuregated-crd-manifests/infrastructures.config.openshift.io/VSphereMultiNetworks.yaml b/config/v1/zz_generated.featuregated-crd-manifests/infrastructures.config.openshift.io/VSphereMultiNetworks.yaml index 8942727344f..a3aaff6c177 100644 --- a/config/v1/zz_generated.featuregated-crd-manifests/infrastructures.config.openshift.io/VSphereMultiNetworks.yaml +++ b/config/v1/zz_generated.featuregated-crd-manifests/infrastructures.config.openshift.io/VSphereMultiNetworks.yaml @@ -608,9 +608,9 @@ spec: failureDomains contains the definition of region, zone and the vCenter topology. If this is omitted failure domains (regions and zones) will not be used. items: - description: |- - VSpherePlatformFailureDomainSpec holds the region and zone failure domain and - the vCenter topology of that failure domain. + description: VSpherePlatformFailureDomainSpec holds the + region and zone failure domain and the vCenter topology + of that failure domain. properties: name: description: |- @@ -627,6 +627,61 @@ spec: maxLength: 80 minLength: 1 type: string + regionAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' server: description: server is the fully-qualified domain name or the IP address of the vCenter server. @@ -708,6 +763,61 @@ spec: maxLength: 80 minLength: 1 type: string + zoneAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' required: - name - region @@ -715,6 +825,17 @@ spec: - topology - zone type: object + x-kubernetes-validations: + - message: when zoneAffinity type is HostGroup, regionAffinity + type must be ComputeCluster + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''HostGroup'' ? has(self.regionAffinity) && self.regionAffinity.type + == ''ComputeCluster'' : true' + - message: when zoneAffinity type is ComputeCluster, regionAffinity + type must be Datacenter + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''ComputeCluster'' ? has(self.regionAffinity) && + self.regionAffinity.type == ''Datacenter'' : true' type: array x-kubernetes-list-map-keys: - name diff --git a/config/v1/zz_generated.featuregated-crd-manifests/infrastructures.config.openshift.io/VSphereMultiVCenters.yaml b/config/v1/zz_generated.featuregated-crd-manifests/infrastructures.config.openshift.io/VSphereMultiVCenters.yaml index a583dd3912f..48200786b8d 100644 --- a/config/v1/zz_generated.featuregated-crd-manifests/infrastructures.config.openshift.io/VSphereMultiVCenters.yaml +++ b/config/v1/zz_generated.featuregated-crd-manifests/infrastructures.config.openshift.io/VSphereMultiVCenters.yaml @@ -608,9 +608,9 @@ spec: failureDomains contains the definition of region, zone and the vCenter topology. If this is omitted failure domains (regions and zones) will not be used. items: - description: |- - VSpherePlatformFailureDomainSpec holds the region and zone failure domain and - the vCenter topology of that failure domain. + description: VSpherePlatformFailureDomainSpec holds the + region and zone failure domain and the vCenter topology + of that failure domain. properties: name: description: |- @@ -627,6 +627,61 @@ spec: maxLength: 80 minLength: 1 type: string + regionAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' server: description: server is the fully-qualified domain name or the IP address of the vCenter server. @@ -707,6 +762,61 @@ spec: maxLength: 80 minLength: 1 type: string + zoneAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' required: - name - region @@ -714,6 +824,17 @@ spec: - topology - zone type: object + x-kubernetes-validations: + - message: when zoneAffinity type is HostGroup, regionAffinity + type must be ComputeCluster + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''HostGroup'' ? has(self.regionAffinity) && self.regionAffinity.type + == ''ComputeCluster'' : true' + - message: when zoneAffinity type is ComputeCluster, regionAffinity + type must be Datacenter + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''ComputeCluster'' ? has(self.regionAffinity) && + self.regionAffinity.type == ''Datacenter'' : true' type: array x-kubernetes-list-map-keys: - name diff --git a/config/v1/zz_generated.swagger_doc_generated.go b/config/v1/zz_generated.swagger_doc_generated.go index c580bd8342e..2323d31f300 100644 --- a/config/v1/zz_generated.swagger_doc_generated.go +++ b/config/v1/zz_generated.swagger_doc_generated.go @@ -1735,13 +1735,26 @@ func (PowerVSServiceEndpoint) SwaggerDoc() map[string]string { return map_PowerVSServiceEndpoint } +var map_VSphereFailureDomainAffinity = map[string]string{ + "": "VSphereFailureDomainAffinity contains the vCenter cluster vm-host group (virtual machine and host types) and the vm-host affinity rule that together creates a affinity configuration for vm-host based zonal. This configuration within vCenter creates the required association between a failure domain, virtual machines and ESXi hosts to create a vm-host based zone.", + "vmGroup": "vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. This field is required when the VSphereFailureDomain ZoneType is HostGroup", + "hostGroup": "hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. This field is required when the VSphereFailureDomain ZoneType is HostGroup", + "vmHostRule": "vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. This field is required when the VSphereFailureDomain ZoneType is HostGroup", +} + +func (VSphereFailureDomainAffinity) SwaggerDoc() map[string]string { + return map_VSphereFailureDomainAffinity +} + var map_VSpherePlatformFailureDomainSpec = map[string]string{ - "": "VSpherePlatformFailureDomainSpec holds the region and zone failure domain and the vCenter topology of that failure domain.", - "name": "name defines the arbitrary but unique name of a failure domain.", - "region": "region defines the name of a region tag that will be attached to a vCenter datacenter. The tag category in vCenter must be named openshift-region.", - "zone": "zone defines the name of a zone tag that will be attached to a vCenter cluster. The tag category in vCenter must be named openshift-zone.", - "server": "server is the fully-qualified domain name or the IP address of the vCenter server.", - "topology": "Topology describes a given failure domain using vSphere constructs", + "": "VSpherePlatformFailureDomainSpec holds the region and zone failure domain and the vCenter topology of that failure domain.", + "name": "name defines the arbitrary but unique name of a failure domain.", + "region": "region defines the name of a region tag that will be attached to a vCenter datacenter. The tag category in vCenter must be named openshift-region.", + "zone": "zone defines the name of a zone tag that will be attached to a vCenter cluster. The tag category in vCenter must be named openshift-zone.", + "regionAffinity": "affinity holds the VMGroup and the HostGroup names in vCenter corresponds to a vm-host group of type Virtual Machine and Host respectively. Is also contains the VMHostRule which is an affinity vm-host rule in vCenter.", + "zoneAffinity": "affinity holds the VMGroup and the HostGroup names in vCenter corresponds to a vm-host group of type Virtual Machine and Host respectively. Is also contains the VMHostRule which is an affinity vm-host rule in vCenter.", + "server": "server is the fully-qualified domain name or the IP address of the vCenter server.", + "topology": "Topology describes a given failure domain using vSphere constructs", } func (VSpherePlatformFailureDomainSpec) SwaggerDoc() map[string]string { diff --git a/features.md b/features.md index e668fc88b36..dcf833769fa 100644 --- a/features.md +++ b/features.md @@ -46,6 +46,7 @@ | UpgradeStatus| | | Enabled | Enabled | Enabled | Enabled | | UserNamespacesPodSecurityStandards| | | Enabled | Enabled | Enabled | Enabled | | UserNamespacesSupport| | | Enabled | Enabled | Enabled | Enabled | +| VSphereHostVMGroupZonal| | | Enabled | Enabled | Enabled | Enabled | | VSphereMultiNetworks| | | Enabled | Enabled | Enabled | Enabled | | VSphereMultiVCenters| | | Enabled | Enabled | Enabled | Enabled | | VolumeGroupSnapshot| | | Enabled | Enabled | Enabled | Enabled | diff --git a/features/features.go b/features/features.go index 7f496239543..495e99e76f1 100644 --- a/features/features.go +++ b/features/features.go @@ -175,6 +175,13 @@ var ( enableIn(configv1.Default, configv1.DevPreviewNoUpgrade, configv1.TechPreviewNoUpgrade). mustRegister() + FeatureGateVSphereHostVMGroupZonal = newFeatureGate("VSphereHostVMGroupZonal"). + reportProblemsToJiraComponent("splat"). + contactPerson("jcpowermac"). + productScope(ocpSpecific). + enableIn(configv1.DevPreviewNoUpgrade, configv1.TechPreviewNoUpgrade). + mustRegister() + FeatureGateVSphereMultiVCenters = newFeatureGate("VSphereMultiVCenters"). reportProblemsToJiraComponent("splat"). contactPerson("vr4manta"). diff --git a/machine/v1beta1/types_vsphereprovider.go b/machine/v1beta1/types_vsphereprovider.go index f458cbf6eff..f55839e06dc 100644 --- a/machine/v1beta1/types_vsphereprovider.go +++ b/machine/v1beta1/types_vsphereprovider.go @@ -190,6 +190,9 @@ 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. + // +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..3c4cb90eb40 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/machineconfiguration/v1/zz_generated.crd-manifests/0000_80_machine-config_01_controllerconfigs-CustomNoUpgrade.crd.yaml b/machineconfiguration/v1/zz_generated.crd-manifests/0000_80_machine-config_01_controllerconfigs-CustomNoUpgrade.crd.yaml index 42a59890bac..9eeff59509a 100644 --- a/machineconfiguration/v1/zz_generated.crd-manifests/0000_80_machine-config_01_controllerconfigs-CustomNoUpgrade.crd.yaml +++ b/machineconfiguration/v1/zz_generated.crd-manifests/0000_80_machine-config_01_controllerconfigs-CustomNoUpgrade.crd.yaml @@ -895,9 +895,9 @@ spec: failureDomains contains the definition of region, zone and the vCenter topology. If this is omitted failure domains (regions and zones) will not be used. items: - description: |- - VSpherePlatformFailureDomainSpec holds the region and zone failure domain and - the vCenter topology of that failure domain. + description: VSpherePlatformFailureDomainSpec holds + the region and zone failure domain and the vCenter + topology of that failure domain. properties: name: description: |- @@ -914,6 +914,65 @@ spec: maxLength: 80 minLength: 1 type: string + regionAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + enum: + - HostGroup + - ComputeCluster + - Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type + must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' server: description: server is the fully-qualified domain name or the IP address of the vCenter server. @@ -1010,6 +1069,65 @@ spec: maxLength: 80 minLength: 1 type: string + zoneAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + enum: + - HostGroup + - ComputeCluster + - Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type + must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' required: - name - region @@ -1017,6 +1135,19 @@ spec: - topology - zone type: object + x-kubernetes-validations: + - message: when zoneAffinity type is HostGroup, + regionAffinity type must be ComputeCluster + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''HostGroup'' ? has(self.regionAffinity) + && self.regionAffinity.type == ''ComputeCluster'' + : true' + - message: when zoneAffinity type is ComputeCluster, + regionAffinity type must be Datacenter + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''ComputeCluster'' ? has(self.regionAffinity) + && self.regionAffinity.type == ''Datacenter'' + : true' type: array x-kubernetes-list-map-keys: - name diff --git a/machineconfiguration/v1/zz_generated.crd-manifests/0000_80_machine-config_01_controllerconfigs-Default.crd.yaml b/machineconfiguration/v1/zz_generated.crd-manifests/0000_80_machine-config_01_controllerconfigs-Default.crd.yaml index d83951b43d8..d392552bc06 100644 --- a/machineconfiguration/v1/zz_generated.crd-manifests/0000_80_machine-config_01_controllerconfigs-Default.crd.yaml +++ b/machineconfiguration/v1/zz_generated.crd-manifests/0000_80_machine-config_01_controllerconfigs-Default.crd.yaml @@ -895,9 +895,9 @@ spec: failureDomains contains the definition of region, zone and the vCenter topology. If this is omitted failure domains (regions and zones) will not be used. items: - description: |- - VSpherePlatformFailureDomainSpec holds the region and zone failure domain and - the vCenter topology of that failure domain. + description: VSpherePlatformFailureDomainSpec holds + the region and zone failure domain and the vCenter + topology of that failure domain. properties: name: description: |- @@ -914,6 +914,61 @@ spec: maxLength: 80 minLength: 1 type: string + regionAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type + must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' server: description: server is the fully-qualified domain name or the IP address of the vCenter server. @@ -1010,6 +1065,61 @@ spec: maxLength: 80 minLength: 1 type: string + zoneAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type + must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' required: - name - region @@ -1017,6 +1127,19 @@ spec: - topology - zone type: object + x-kubernetes-validations: + - message: when zoneAffinity type is HostGroup, + regionAffinity type must be ComputeCluster + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''HostGroup'' ? has(self.regionAffinity) + && self.regionAffinity.type == ''ComputeCluster'' + : true' + - message: when zoneAffinity type is ComputeCluster, + regionAffinity type must be Datacenter + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''ComputeCluster'' ? has(self.regionAffinity) + && self.regionAffinity.type == ''Datacenter'' + : true' type: array x-kubernetes-list-map-keys: - name diff --git a/machineconfiguration/v1/zz_generated.crd-manifests/0000_80_machine-config_01_controllerconfigs-DevPreviewNoUpgrade.crd.yaml b/machineconfiguration/v1/zz_generated.crd-manifests/0000_80_machine-config_01_controllerconfigs-DevPreviewNoUpgrade.crd.yaml index ddd72e05e89..fd4da3c11fc 100644 --- a/machineconfiguration/v1/zz_generated.crd-manifests/0000_80_machine-config_01_controllerconfigs-DevPreviewNoUpgrade.crd.yaml +++ b/machineconfiguration/v1/zz_generated.crd-manifests/0000_80_machine-config_01_controllerconfigs-DevPreviewNoUpgrade.crd.yaml @@ -895,9 +895,9 @@ spec: failureDomains contains the definition of region, zone and the vCenter topology. If this is omitted failure domains (regions and zones) will not be used. items: - description: |- - VSpherePlatformFailureDomainSpec holds the region and zone failure domain and - the vCenter topology of that failure domain. + description: VSpherePlatformFailureDomainSpec holds + the region and zone failure domain and the vCenter + topology of that failure domain. properties: name: description: |- @@ -914,6 +914,65 @@ spec: maxLength: 80 minLength: 1 type: string + regionAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + enum: + - HostGroup + - ComputeCluster + - Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type + must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' server: description: server is the fully-qualified domain name or the IP address of the vCenter server. @@ -1010,6 +1069,65 @@ spec: maxLength: 80 minLength: 1 type: string + zoneAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + enum: + - HostGroup + - ComputeCluster + - Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type + must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' required: - name - region @@ -1017,6 +1135,19 @@ spec: - topology - zone type: object + x-kubernetes-validations: + - message: when zoneAffinity type is HostGroup, + regionAffinity type must be ComputeCluster + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''HostGroup'' ? has(self.regionAffinity) + && self.regionAffinity.type == ''ComputeCluster'' + : true' + - message: when zoneAffinity type is ComputeCluster, + regionAffinity type must be Datacenter + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''ComputeCluster'' ? has(self.regionAffinity) + && self.regionAffinity.type == ''Datacenter'' + : true' type: array x-kubernetes-list-map-keys: - name diff --git a/machineconfiguration/v1/zz_generated.crd-manifests/0000_80_machine-config_01_controllerconfigs-TechPreviewNoUpgrade.crd.yaml b/machineconfiguration/v1/zz_generated.crd-manifests/0000_80_machine-config_01_controllerconfigs-TechPreviewNoUpgrade.crd.yaml index 2e9b84d78d6..2da55b1da03 100644 --- a/machineconfiguration/v1/zz_generated.crd-manifests/0000_80_machine-config_01_controllerconfigs-TechPreviewNoUpgrade.crd.yaml +++ b/machineconfiguration/v1/zz_generated.crd-manifests/0000_80_machine-config_01_controllerconfigs-TechPreviewNoUpgrade.crd.yaml @@ -895,9 +895,9 @@ spec: failureDomains contains the definition of region, zone and the vCenter topology. If this is omitted failure domains (regions and zones) will not be used. items: - description: |- - VSpherePlatformFailureDomainSpec holds the region and zone failure domain and - the vCenter topology of that failure domain. + description: VSpherePlatformFailureDomainSpec holds + the region and zone failure domain and the vCenter + topology of that failure domain. properties: name: description: |- @@ -914,6 +914,65 @@ spec: maxLength: 80 minLength: 1 type: string + regionAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + enum: + - HostGroup + - ComputeCluster + - Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type + must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' server: description: server is the fully-qualified domain name or the IP address of the vCenter server. @@ -1010,6 +1069,65 @@ spec: maxLength: 80 minLength: 1 type: string + zoneAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + enum: + - HostGroup + - ComputeCluster + - Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type + must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' required: - name - region @@ -1017,6 +1135,19 @@ spec: - topology - zone type: object + x-kubernetes-validations: + - message: when zoneAffinity type is HostGroup, + regionAffinity type must be ComputeCluster + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''HostGroup'' ? has(self.regionAffinity) + && self.regionAffinity.type == ''ComputeCluster'' + : true' + - message: when zoneAffinity type is ComputeCluster, + regionAffinity type must be Datacenter + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''ComputeCluster'' ? has(self.regionAffinity) + && self.regionAffinity.type == ''Datacenter'' + : true' type: array x-kubernetes-list-map-keys: - name diff --git a/machineconfiguration/v1/zz_generated.featuregated-crd-manifests.yaml b/machineconfiguration/v1/zz_generated.featuregated-crd-manifests.yaml index c2cac2c544d..20fe623d3d2 100644 --- a/machineconfiguration/v1/zz_generated.featuregated-crd-manifests.yaml +++ b/machineconfiguration/v1/zz_generated.featuregated-crd-manifests.yaml @@ -32,6 +32,7 @@ controllerconfigs.machineconfiguration.openshift.io: - GCPClusterHostedDNS - GCPLabelsTags - VSphereControlPlaneMachineSet + - VSphereHostVMGroupZonal - VSphereMultiNetworks - VSphereMultiVCenters FilenameOperatorName: machine-config diff --git a/machineconfiguration/v1/zz_generated.featuregated-crd-manifests/controllerconfigs.machineconfiguration.openshift.io/AAA_ungated.yaml b/machineconfiguration/v1/zz_generated.featuregated-crd-manifests/controllerconfigs.machineconfiguration.openshift.io/AAA_ungated.yaml index 0e5c1ea0500..422186cfd3b 100644 --- a/machineconfiguration/v1/zz_generated.featuregated-crd-manifests/controllerconfigs.machineconfiguration.openshift.io/AAA_ungated.yaml +++ b/machineconfiguration/v1/zz_generated.featuregated-crd-manifests/controllerconfigs.machineconfiguration.openshift.io/AAA_ungated.yaml @@ -895,9 +895,9 @@ spec: failureDomains contains the definition of region, zone and the vCenter topology. If this is omitted failure domains (regions and zones) will not be used. items: - description: |- - VSpherePlatformFailureDomainSpec holds the region and zone failure domain and - the vCenter topology of that failure domain. + description: VSpherePlatformFailureDomainSpec holds + the region and zone failure domain and the vCenter + topology of that failure domain. properties: name: description: |- @@ -914,6 +914,61 @@ spec: maxLength: 80 minLength: 1 type: string + regionAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type + must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' server: description: server is the fully-qualified domain name or the IP address of the vCenter server. @@ -995,6 +1050,61 @@ spec: maxLength: 80 minLength: 1 type: string + zoneAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type + must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' required: - name - region @@ -1002,6 +1112,19 @@ spec: - topology - zone type: object + x-kubernetes-validations: + - message: when zoneAffinity type is HostGroup, + regionAffinity type must be ComputeCluster + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''HostGroup'' ? has(self.regionAffinity) + && self.regionAffinity.type == ''ComputeCluster'' + : true' + - message: when zoneAffinity type is ComputeCluster, + regionAffinity type must be Datacenter + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''ComputeCluster'' ? has(self.regionAffinity) + && self.regionAffinity.type == ''Datacenter'' + : true' type: array x-kubernetes-list-map-keys: - name diff --git a/machineconfiguration/v1/zz_generated.featuregated-crd-manifests/controllerconfigs.machineconfiguration.openshift.io/BareMetalLoadBalancer.yaml b/machineconfiguration/v1/zz_generated.featuregated-crd-manifests/controllerconfigs.machineconfiguration.openshift.io/BareMetalLoadBalancer.yaml index ade67de0b23..db960256cb8 100644 --- a/machineconfiguration/v1/zz_generated.featuregated-crd-manifests/controllerconfigs.machineconfiguration.openshift.io/BareMetalLoadBalancer.yaml +++ b/machineconfiguration/v1/zz_generated.featuregated-crd-manifests/controllerconfigs.machineconfiguration.openshift.io/BareMetalLoadBalancer.yaml @@ -895,9 +895,9 @@ spec: failureDomains contains the definition of region, zone and the vCenter topology. If this is omitted failure domains (regions and zones) will not be used. items: - description: |- - VSpherePlatformFailureDomainSpec holds the region and zone failure domain and - the vCenter topology of that failure domain. + description: VSpherePlatformFailureDomainSpec holds + the region and zone failure domain and the vCenter + topology of that failure domain. properties: name: description: |- @@ -914,6 +914,61 @@ spec: maxLength: 80 minLength: 1 type: string + regionAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type + must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' server: description: server is the fully-qualified domain name or the IP address of the vCenter server. @@ -994,6 +1049,61 @@ spec: maxLength: 80 minLength: 1 type: string + zoneAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type + must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' required: - name - region @@ -1001,6 +1111,19 @@ spec: - topology - zone type: object + x-kubernetes-validations: + - message: when zoneAffinity type is HostGroup, + regionAffinity type must be ComputeCluster + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''HostGroup'' ? has(self.regionAffinity) + && self.regionAffinity.type == ''ComputeCluster'' + : true' + - message: when zoneAffinity type is ComputeCluster, + regionAffinity type must be Datacenter + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''ComputeCluster'' ? has(self.regionAffinity) + && self.regionAffinity.type == ''Datacenter'' + : true' type: array x-kubernetes-list-map-keys: - name diff --git a/machineconfiguration/v1/zz_generated.featuregated-crd-manifests/controllerconfigs.machineconfiguration.openshift.io/GCPClusterHostedDNS.yaml b/machineconfiguration/v1/zz_generated.featuregated-crd-manifests/controllerconfigs.machineconfiguration.openshift.io/GCPClusterHostedDNS.yaml index f953ca020e2..11fcc4ca4e2 100644 --- a/machineconfiguration/v1/zz_generated.featuregated-crd-manifests/controllerconfigs.machineconfiguration.openshift.io/GCPClusterHostedDNS.yaml +++ b/machineconfiguration/v1/zz_generated.featuregated-crd-manifests/controllerconfigs.machineconfiguration.openshift.io/GCPClusterHostedDNS.yaml @@ -895,9 +895,9 @@ spec: failureDomains contains the definition of region, zone and the vCenter topology. If this is omitted failure domains (regions and zones) will not be used. items: - description: |- - VSpherePlatformFailureDomainSpec holds the region and zone failure domain and - the vCenter topology of that failure domain. + description: VSpherePlatformFailureDomainSpec holds + the region and zone failure domain and the vCenter + topology of that failure domain. properties: name: description: |- @@ -914,6 +914,61 @@ spec: maxLength: 80 minLength: 1 type: string + regionAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type + must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' server: description: server is the fully-qualified domain name or the IP address of the vCenter server. @@ -994,6 +1049,61 @@ spec: maxLength: 80 minLength: 1 type: string + zoneAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type + must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' required: - name - region @@ -1001,6 +1111,19 @@ spec: - topology - zone type: object + x-kubernetes-validations: + - message: when zoneAffinity type is HostGroup, + regionAffinity type must be ComputeCluster + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''HostGroup'' ? has(self.regionAffinity) + && self.regionAffinity.type == ''ComputeCluster'' + : true' + - message: when zoneAffinity type is ComputeCluster, + regionAffinity type must be Datacenter + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''ComputeCluster'' ? has(self.regionAffinity) + && self.regionAffinity.type == ''Datacenter'' + : true' type: array x-kubernetes-list-map-keys: - name diff --git a/machineconfiguration/v1/zz_generated.featuregated-crd-manifests/controllerconfigs.machineconfiguration.openshift.io/GCPLabelsTags.yaml b/machineconfiguration/v1/zz_generated.featuregated-crd-manifests/controllerconfigs.machineconfiguration.openshift.io/GCPLabelsTags.yaml index f19c0437ebb..2e0a927ae68 100644 --- a/machineconfiguration/v1/zz_generated.featuregated-crd-manifests/controllerconfigs.machineconfiguration.openshift.io/GCPLabelsTags.yaml +++ b/machineconfiguration/v1/zz_generated.featuregated-crd-manifests/controllerconfigs.machineconfiguration.openshift.io/GCPLabelsTags.yaml @@ -895,9 +895,9 @@ spec: failureDomains contains the definition of region, zone and the vCenter topology. If this is omitted failure domains (regions and zones) will not be used. items: - description: |- - VSpherePlatformFailureDomainSpec holds the region and zone failure domain and - the vCenter topology of that failure domain. + description: VSpherePlatformFailureDomainSpec holds + the region and zone failure domain and the vCenter + topology of that failure domain. properties: name: description: |- @@ -914,6 +914,61 @@ spec: maxLength: 80 minLength: 1 type: string + regionAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type + must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' server: description: server is the fully-qualified domain name or the IP address of the vCenter server. @@ -994,6 +1049,61 @@ spec: maxLength: 80 minLength: 1 type: string + zoneAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type + must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' required: - name - region @@ -1001,6 +1111,19 @@ spec: - topology - zone type: object + x-kubernetes-validations: + - message: when zoneAffinity type is HostGroup, + regionAffinity type must be ComputeCluster + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''HostGroup'' ? has(self.regionAffinity) + && self.regionAffinity.type == ''ComputeCluster'' + : true' + - message: when zoneAffinity type is ComputeCluster, + regionAffinity type must be Datacenter + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''ComputeCluster'' ? has(self.regionAffinity) + && self.regionAffinity.type == ''Datacenter'' + : true' type: array x-kubernetes-list-map-keys: - name diff --git a/machineconfiguration/v1/zz_generated.featuregated-crd-manifests/controllerconfigs.machineconfiguration.openshift.io/VSphereControlPlaneMachineSet.yaml b/machineconfiguration/v1/zz_generated.featuregated-crd-manifests/controllerconfigs.machineconfiguration.openshift.io/VSphereControlPlaneMachineSet.yaml index befd4db6722..292021aef00 100644 --- a/machineconfiguration/v1/zz_generated.featuregated-crd-manifests/controllerconfigs.machineconfiguration.openshift.io/VSphereControlPlaneMachineSet.yaml +++ b/machineconfiguration/v1/zz_generated.featuregated-crd-manifests/controllerconfigs.machineconfiguration.openshift.io/VSphereControlPlaneMachineSet.yaml @@ -895,9 +895,9 @@ spec: failureDomains contains the definition of region, zone and the vCenter topology. If this is omitted failure domains (regions and zones) will not be used. items: - description: |- - VSpherePlatformFailureDomainSpec holds the region and zone failure domain and - the vCenter topology of that failure domain. + description: VSpherePlatformFailureDomainSpec holds + the region and zone failure domain and the vCenter + topology of that failure domain. properties: name: description: |- @@ -914,6 +914,61 @@ spec: maxLength: 80 minLength: 1 type: string + regionAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type + must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' server: description: server is the fully-qualified domain name or the IP address of the vCenter server. @@ -1009,6 +1064,61 @@ spec: maxLength: 80 minLength: 1 type: string + zoneAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type + must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' required: - name - region @@ -1016,6 +1126,19 @@ spec: - topology - zone type: object + x-kubernetes-validations: + - message: when zoneAffinity type is HostGroup, + regionAffinity type must be ComputeCluster + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''HostGroup'' ? has(self.regionAffinity) + && self.regionAffinity.type == ''ComputeCluster'' + : true' + - message: when zoneAffinity type is ComputeCluster, + regionAffinity type must be Datacenter + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''ComputeCluster'' ? has(self.regionAffinity) + && self.regionAffinity.type == ''Datacenter'' + : true' type: array x-kubernetes-list-map-keys: - name diff --git a/machineconfiguration/v1/zz_generated.featuregated-crd-manifests/controllerconfigs.machineconfiguration.openshift.io/VSphereHostVMGroupZonal.yaml b/machineconfiguration/v1/zz_generated.featuregated-crd-manifests/controllerconfigs.machineconfiguration.openshift.io/VSphereHostVMGroupZonal.yaml new file mode 100644 index 00000000000..3d160577b85 --- /dev/null +++ b/machineconfiguration/v1/zz_generated.featuregated-crd-manifests/controllerconfigs.machineconfiguration.openshift.io/VSphereHostVMGroupZonal.yaml @@ -0,0 +1,2535 @@ +apiVersion: apiextensions.k8s.io/v1 +kind: CustomResourceDefinition +metadata: + annotations: + api-approved.openshift.io: https://github.com/openshift/api/pull/1453 + api.openshift.io/filename-cvo-runlevel: "0000_80" + api.openshift.io/filename-operator: machine-config + api.openshift.io/filename-ordering: "01" + feature-gate.release.openshift.io/VSphereHostVMGroupZonal: "true" + labels: + openshift.io/operator-managed: "" + name: controllerconfigs.machineconfiguration.openshift.io +spec: + group: machineconfiguration.openshift.io + names: + kind: ControllerConfig + listKind: ControllerConfigList + plural: controllerconfigs + singular: controllerconfig + scope: Cluster + versions: + - name: v1 + schema: + openAPIV3Schema: + description: |- + ControllerConfig describes configuration for MachineConfigController. + This is currently only used to drive the MachineConfig objects generated by the TemplateController. + + Compatibility level 1: Stable within a major release for a minimum of 12 months or 3 minor releases (whichever is longer). + properties: + apiVersion: + description: |- + APIVersion defines the versioned schema of this representation of an object. + Servers should convert recognized schemas to the latest internal value, and + may reject unrecognized values. + More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + type: string + kind: + description: |- + Kind is a string value representing the REST resource this object represents. + Servers may infer this from the endpoint the client submits requests to. + Cannot be updated. + In CamelCase. + More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + type: string + metadata: + type: object + spec: + description: ControllerConfigSpec is the spec for ControllerConfig resource. + properties: + additionalTrustBundle: + description: |- + additionalTrustBundle is a certificate bundle that will be added to the nodes + trusted certificate store. + format: byte + nullable: true + type: string + baseOSContainerImage: + description: BaseOSContainerImage is the new-format container image + for operating system updates. + type: string + baseOSExtensionsContainerImage: + description: BaseOSExtensionsContainerImage is the matching extensions + container for the new-format container + type: string + cloudProviderCAData: + description: cloudProvider specifies the cloud provider CA data + format: byte + nullable: true + type: string + cloudProviderConfig: + description: cloudProviderConfig is the configuration for the given + cloud provider + type: string + clusterDNSIP: + description: clusterDNSIP is the cluster DNS IP address + type: string + dns: + description: dns holds the cluster dns details + nullable: true + properties: + apiVersion: + description: |- + APIVersion defines the versioned schema of this representation of an object. + Servers should convert recognized schemas to the latest internal value, and + may reject unrecognized values. + More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + type: string + kind: + description: |- + Kind is a string value representing the REST resource this object represents. + Servers may infer this from the endpoint the client submits requests to. + Cannot be updated. + In CamelCase. + More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + type: string + metadata: + description: |- + metadata is the standard object's metadata. + More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + type: object + spec: + description: spec holds user settable values for configuration + properties: + baseDomain: + description: |- + baseDomain is the base domain of the cluster. All managed DNS records will + be sub-domains of this base. + + For example, given the base domain `openshift.example.com`, an API server + DNS record may be created for `cluster-api.openshift.example.com`. + + Once set, this field cannot be changed. + type: string + platform: + description: |- + platform holds configuration specific to the underlying + infrastructure provider for DNS. + When omitted, this means the user has no opinion and the platform is left + to choose reasonable defaults. These defaults are subject to change over time. + properties: + aws: + description: aws contains DNS configuration specific to + the Amazon Web Services cloud provider. + properties: + privateZoneIAMRole: + description: |- + privateZoneIAMRole contains the ARN of an IAM role that should be assumed when performing + operations on the cluster's private hosted zone specified in the cluster DNS config. + When left empty, no role should be assumed. + pattern: ^arn:(aws|aws-cn|aws-us-gov):iam::[0-9]{12}:role\/.*$ + type: string + type: object + type: + description: |- + type is the underlying infrastructure provider for the cluster. + Allowed values: "", "AWS". + + Individual components may not support all platforms, + and must handle unrecognized platforms with best-effort defaults. + enum: + - "" + - AWS + - Azure + - BareMetal + - GCP + - Libvirt + - OpenStack + - None + - VSphere + - oVirt + - IBMCloud + - KubeVirt + - EquinixMetal + - PowerVS + - AlibabaCloud + - Nutanix + - External + type: string + x-kubernetes-validations: + - message: allowed values are '' and 'AWS' + rule: self in ['','AWS'] + required: + - type + type: object + x-kubernetes-validations: + - message: aws configuration is required when platform is + AWS, and forbidden otherwise + rule: 'has(self.type) && self.type == ''AWS'' ? has(self.aws) + : !has(self.aws)' + privateZone: + description: |- + privateZone is the location where all the DNS records that are only available internally + to the cluster exist. + + If this field is nil, no private records should be created. + + Once set, this field cannot be changed. + properties: + id: + description: |- + id is the identifier that can be used to find the DNS hosted zone. + + on AWS zone can be fetched using `ID` as id in [1] + on Azure zone can be fetched using `ID` as a pre-determined name in [2], + on GCP zone can be fetched using `ID` as a pre-determined name in [3]. + + [1]: https://docs.aws.amazon.com/cli/latest/reference/route53/get-hosted-zone.html#options + [2]: https://docs.microsoft.com/en-us/cli/azure/network/dns/zone?view=azure-cli-latest#az-network-dns-zone-show + [3]: https://cloud.google.com/dns/docs/reference/v1/managedZones/get + type: string + tags: + additionalProperties: + type: string + description: |- + tags can be used to query the DNS hosted zone. + + on AWS, resourcegroupstaggingapi [1] can be used to fetch a zone using `Tags` as tag-filters, + + [1]: https://docs.aws.amazon.com/cli/latest/reference/resourcegroupstaggingapi/get-resources.html#options + type: object + type: object + publicZone: + description: |- + publicZone is the location where all the DNS records that are publicly accessible to + the internet exist. + + If this field is nil, no public records should be created. + + Once set, this field cannot be changed. + properties: + id: + description: |- + id is the identifier that can be used to find the DNS hosted zone. + + on AWS zone can be fetched using `ID` as id in [1] + on Azure zone can be fetched using `ID` as a pre-determined name in [2], + on GCP zone can be fetched using `ID` as a pre-determined name in [3]. + + [1]: https://docs.aws.amazon.com/cli/latest/reference/route53/get-hosted-zone.html#options + [2]: https://docs.microsoft.com/en-us/cli/azure/network/dns/zone?view=azure-cli-latest#az-network-dns-zone-show + [3]: https://cloud.google.com/dns/docs/reference/v1/managedZones/get + type: string + tags: + additionalProperties: + type: string + description: |- + tags can be used to query the DNS hosted zone. + + on AWS, resourcegroupstaggingapi [1] can be used to fetch a zone using `Tags` as tag-filters, + + [1]: https://docs.aws.amazon.com/cli/latest/reference/resourcegroupstaggingapi/get-resources.html#options + type: object + type: object + type: object + status: + description: status holds observed values from the cluster. They + may not be overridden. + type: object + required: + - spec + type: object + x-kubernetes-embedded-resource: true + etcdDiscoveryDomain: + description: etcdDiscoveryDomain is deprecated, use Infra.Status.EtcdDiscoveryDomain + instead + type: string + imageRegistryBundleData: + description: imageRegistryBundleData is the ImageRegistryData + items: + description: ImageRegistryBundle contains information for writing + image registry certificates + properties: + data: + description: data holds the contents of the bundle that will + be written to the file location + format: byte + type: string + file: + description: file holds the name of the file where the bundle + will be written to disk + type: string + required: + - data + - file + type: object + type: array + x-kubernetes-list-type: atomic + imageRegistryBundleUserData: + description: imageRegistryBundleUserData is Image Registry Data provided + by the user + items: + description: ImageRegistryBundle contains information for writing + image registry certificates + properties: + data: + description: data holds the contents of the bundle that will + be written to the file location + format: byte + type: string + file: + description: file holds the name of the file where the bundle + will be written to disk + type: string + required: + - data + - file + type: object + type: array + x-kubernetes-list-type: atomic + images: + additionalProperties: + type: string + description: images is map of images that are used by the controller + to render templates under ./templates/ + type: object + infra: + description: infra holds the infrastructure details + nullable: true + properties: + apiVersion: + description: |- + APIVersion defines the versioned schema of this representation of an object. + Servers should convert recognized schemas to the latest internal value, and + may reject unrecognized values. + More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + type: string + kind: + description: |- + Kind is a string value representing the REST resource this object represents. + Servers may infer this from the endpoint the client submits requests to. + Cannot be updated. + In CamelCase. + More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + type: string + metadata: + description: |- + metadata is the standard object's metadata. + More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + type: object + spec: + description: spec holds user settable values for configuration + properties: + cloudConfig: + description: |- + cloudConfig is a reference to a ConfigMap containing the cloud provider configuration file. + This configuration file is used to configure the Kubernetes cloud provider integration + when using the built-in cloud provider integration or the external cloud controller manager. + The namespace for this config map is openshift-config. + + cloudConfig should only be consumed by the kube_cloud_config controller. + The controller is responsible for using the user configuration in the spec + for various platforms and combining that with the user provided ConfigMap in this field + to create a stitched kube cloud config. + The controller generates a ConfigMap `kube-cloud-config` in `openshift-config-managed` namespace + with the kube cloud config is stored in `cloud.conf` key. + All the clients are expected to use the generated ConfigMap only. + properties: + key: + description: Key allows pointing to a specific key/value + inside of the configmap. This is useful for logical + file references. + type: string + name: + type: string + type: object + platformSpec: + description: |- + platformSpec holds desired information specific to the underlying + infrastructure provider. + properties: + alibabaCloud: + description: AlibabaCloud contains settings specific to + the Alibaba Cloud infrastructure provider. + type: object + aws: + description: AWS contains settings specific to the Amazon + Web Services infrastructure provider. + properties: + serviceEndpoints: + description: |- + serviceEndpoints list contains custom endpoints which will override default + service endpoint of AWS Services. + There must be only one ServiceEndpoint for a service. + items: + description: |- + AWSServiceEndpoint store the configuration of a custom url to + override existing defaults of AWS Services. + properties: + name: + description: |- + name is the name of the AWS service. + The list of all the service names can be found at https://docs.aws.amazon.com/general/latest/gr/aws-service-information.html + This must be provided and cannot be empty. + pattern: ^[a-z0-9-]+$ + type: string + url: + description: |- + url is fully qualified URI with scheme https, that overrides the default generated + endpoint for a client. + This must be provided and cannot be empty. + pattern: ^https:// + type: string + type: object + type: array + x-kubernetes-list-type: atomic + type: object + azure: + description: Azure contains settings specific to the Azure + infrastructure provider. + type: object + baremetal: + description: BareMetal contains settings specific to the + BareMetal platform. + properties: + apiServerInternalIPs: + description: |- + apiServerInternalIPs are the IP addresses to contact the Kubernetes API + server that can be used by components inside the cluster, like kubelets + using the infrastructure rather than Kubernetes networking. These are the + IPs for a self-hosted load balancer in front of the API servers. + In dual stack clusters this list contains two IP addresses, one from IPv4 + family and one from IPv6. + In single stack clusters a single IP address is expected. + When omitted, values from the status.apiServerInternalIPs will be used. + Once set, the list cannot be completely removed (but its second entry can). + items: + description: IP is an IP address (for example, "10.0.0.0" + or "fd00::"). + maxLength: 39 + minLength: 1 + type: string + x-kubernetes-validations: + - message: value must be a valid IP address + rule: isIP(self) + maxItems: 2 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - message: apiServerInternalIPs must contain at most + one IPv4 address and at most one IPv6 address + rule: 'size(self) == 2 && isIP(self[0]) && isIP(self[1]) + ? ip(self[0]).family() != ip(self[1]).family() + : true' + ingressIPs: + description: |- + ingressIPs are the external IPs which route to the default ingress + controller. The IPs are suitable targets of a wildcard DNS record used to + resolve default route host names. + In dual stack clusters this list contains two IP addresses, one from IPv4 + family and one from IPv6. + In single stack clusters a single IP address is expected. + When omitted, values from the status.ingressIPs will be used. + Once set, the list cannot be completely removed (but its second entry can). + items: + description: IP is an IP address (for example, "10.0.0.0" + or "fd00::"). + maxLength: 39 + minLength: 1 + type: string + x-kubernetes-validations: + - message: value must be a valid IP address + rule: isIP(self) + maxItems: 2 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - message: ingressIPs must contain at most one IPv4 + address and at most one IPv6 address + rule: 'size(self) == 2 && isIP(self[0]) && isIP(self[1]) + ? ip(self[0]).family() != ip(self[1]).family() + : true' + machineNetworks: + description: |- + machineNetworks are IP networks used to connect all the OpenShift cluster + nodes. Each network is provided in the CIDR format and should be IPv4 or IPv6, + for example "10.0.0.0/8" or "fd00::/8". + items: + description: CIDR is an IP address range in CIDR + notation (for example, "10.0.0.0/8" or "fd00::/8"). + maxLength: 43 + minLength: 1 + type: string + x-kubernetes-validations: + - message: value must be a valid CIDR network address + rule: isCIDR(self) + maxItems: 32 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - rule: self.all(x, self.exists_one(y, x == y)) + type: object + x-kubernetes-validations: + - message: apiServerInternalIPs list is required once + set + rule: '!has(oldSelf.apiServerInternalIPs) || has(self.apiServerInternalIPs)' + - message: ingressIPs list is required once set + rule: '!has(oldSelf.ingressIPs) || has(self.ingressIPs)' + equinixMetal: + description: EquinixMetal contains settings specific to + the Equinix Metal infrastructure provider. + type: object + external: + description: |- + ExternalPlatformType represents generic infrastructure provider. + Platform-specific components should be supplemented separately. + properties: + platformName: + default: Unknown + description: |- + PlatformName holds the arbitrary string representing the infrastructure provider name, expected to be set at the installation time. + This field is solely for informational and reporting purposes and is not expected to be used for decision-making. + type: string + x-kubernetes-validations: + - message: platform name cannot be changed once set + rule: oldSelf == 'Unknown' || self == oldSelf + type: object + gcp: + description: GCP contains settings specific to the Google + Cloud Platform infrastructure provider. + type: object + ibmcloud: + description: IBMCloud contains settings specific to the + IBMCloud infrastructure provider. + type: object + kubevirt: + description: Kubevirt contains settings specific to the + kubevirt infrastructure provider. + type: object + nutanix: + description: Nutanix contains settings specific to the + Nutanix infrastructure provider. + properties: + failureDomains: + description: |- + failureDomains configures failure domains information for the Nutanix platform. + When set, the failure domains defined here may be used to spread Machines across + prism element clusters to improve fault tolerance of the cluster. + items: + description: NutanixFailureDomain configures failure + domain information for the Nutanix platform. + properties: + cluster: + description: |- + cluster is to identify the cluster (the Prism Element under management of the Prism Central), + in which the Machine's VM will be created. The cluster identifier (uuid or name) can be obtained + from the Prism Central console or using the prism_central API. + properties: + name: + description: name is the resource name in + the PC. It cannot be empty if the type + is Name. + type: string + type: + description: type is the identifier type + to use for this resource. + enum: + - UUID + - Name + type: string + uuid: + description: uuid is the UUID of the resource + in the PC. It cannot be empty if the type + is UUID. + type: string + required: + - type + type: object + x-kubernetes-validations: + - message: uuid configuration is required when + type is UUID, and forbidden otherwise + rule: 'has(self.type) && self.type == ''UUID'' + ? has(self.uuid) : !has(self.uuid)' + - message: name configuration is required when + type is Name, and forbidden otherwise + rule: 'has(self.type) && self.type == ''Name'' + ? has(self.name) : !has(self.name)' + name: + description: |- + name defines the unique name of a failure domain. + Name is required and must be at most 64 characters in length. + It must consist of only lower case alphanumeric characters and hyphens (-). + It must start and end with an alphanumeric character. + This value is arbitrary and is used to identify the failure domain within the platform. + maxLength: 64 + minLength: 1 + pattern: '[a-z0-9]([-a-z0-9]*[a-z0-9])?' + type: string + subnets: + description: |- + subnets holds a list of identifiers (one or more) of the cluster's network subnets + for the Machine's VM to connect to. The subnet identifiers (uuid or name) can be + obtained from the Prism Central console or using the prism_central API. + items: + description: NutanixResourceIdentifier holds + the identity of a Nutanix PC resource (cluster, + image, subnet, etc.) + properties: + name: + description: name is the resource name + in the PC. It cannot be empty if the + type is Name. + type: string + type: + description: type is the identifier type + to use for this resource. + enum: + - UUID + - Name + type: string + uuid: + description: uuid is the UUID of the resource + in the PC. It cannot be empty if the + type is UUID. + type: string + required: + - type + type: object + x-kubernetes-validations: + - message: uuid configuration is required + when type is UUID, and forbidden otherwise + rule: 'has(self.type) && self.type == ''UUID'' + ? has(self.uuid) : !has(self.uuid)' + - message: name configuration is required + when type is Name, and forbidden otherwise + rule: 'has(self.type) && self.type == ''Name'' + ? has(self.name) : !has(self.name)' + maxItems: 1 + minItems: 1 + type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map + required: + - cluster + - name + - subnets + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + prismCentral: + description: |- + prismCentral holds the endpoint address and port to access the Nutanix Prism Central. + When a cluster-wide proxy is installed, by default, this endpoint will be accessed via the proxy. + Should you wish for communication with this endpoint not to be proxied, please add the endpoint to the + proxy spec.noProxy list. + properties: + address: + description: address is the endpoint address (DNS + name or IP address) of the Nutanix Prism Central + or Element (cluster) + maxLength: 256 + type: string + port: + description: port is the port number to access + the Nutanix Prism Central or Element (cluster) + format: int32 + maximum: 65535 + minimum: 1 + type: integer + required: + - address + - port + type: object + prismElements: + description: |- + prismElements holds one or more endpoint address and port data to access the Nutanix + Prism Elements (clusters) of the Nutanix Prism Central. Currently we only support one + Prism Element (cluster) for an OpenShift cluster, where all the Nutanix resources (VMs, subnets, volumes, etc.) + used in the OpenShift cluster are located. In the future, we may support Nutanix resources (VMs, etc.) + spread over multiple Prism Elements (clusters) of the Prism Central. + items: + description: NutanixPrismElementEndpoint holds the + name and endpoint data for a Prism Element (cluster) + properties: + endpoint: + description: |- + endpoint holds the endpoint address and port data of the Prism Element (cluster). + When a cluster-wide proxy is installed, by default, this endpoint will be accessed via the proxy. + Should you wish for communication with this endpoint not to be proxied, please add the endpoint to the + proxy spec.noProxy list. + properties: + address: + description: address is the endpoint address + (DNS name or IP address) of the Nutanix + Prism Central or Element (cluster) + maxLength: 256 + type: string + port: + description: port is the port number to + access the Nutanix Prism Central or Element + (cluster) + format: int32 + maximum: 65535 + minimum: 1 + type: integer + required: + - address + - port + type: object + name: + description: |- + name is the name of the Prism Element (cluster). This value will correspond with + the cluster field configured on other resources (eg Machines, PVCs, etc). + maxLength: 256 + type: string + required: + - endpoint + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + required: + - prismCentral + - prismElements + type: object + openstack: + description: OpenStack contains settings specific to the + OpenStack infrastructure provider. + properties: + apiServerInternalIPs: + description: |- + apiServerInternalIPs are the IP addresses to contact the Kubernetes API + server that can be used by components inside the cluster, like kubelets + using the infrastructure rather than Kubernetes networking. These are the + IPs for a self-hosted load balancer in front of the API servers. + In dual stack clusters this list contains two IP addresses, one from IPv4 + family and one from IPv6. + In single stack clusters a single IP address is expected. + When omitted, values from the status.apiServerInternalIPs will be used. + Once set, the list cannot be completely removed (but its second entry can). + items: + description: IP is an IP address (for example, "10.0.0.0" + or "fd00::"). + maxLength: 39 + minLength: 1 + type: string + x-kubernetes-validations: + - message: value must be a valid IP address + rule: isIP(self) + maxItems: 2 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - message: apiServerInternalIPs must contain at most + one IPv4 address and at most one IPv6 address + rule: 'size(self) == 2 && isIP(self[0]) && isIP(self[1]) + ? ip(self[0]).family() != ip(self[1]).family() + : true' + ingressIPs: + description: |- + ingressIPs are the external IPs which route to the default ingress + controller. The IPs are suitable targets of a wildcard DNS record used to + resolve default route host names. + In dual stack clusters this list contains two IP addresses, one from IPv4 + family and one from IPv6. + In single stack clusters a single IP address is expected. + When omitted, values from the status.ingressIPs will be used. + Once set, the list cannot be completely removed (but its second entry can). + items: + description: IP is an IP address (for example, "10.0.0.0" + or "fd00::"). + maxLength: 39 + minLength: 1 + type: string + x-kubernetes-validations: + - message: value must be a valid IP address + rule: isIP(self) + maxItems: 2 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - message: ingressIPs must contain at most one IPv4 + address and at most one IPv6 address + rule: 'size(self) == 2 && isIP(self[0]) && isIP(self[1]) + ? ip(self[0]).family() != ip(self[1]).family() + : true' + machineNetworks: + description: |- + machineNetworks are IP networks used to connect all the OpenShift cluster + nodes. Each network is provided in the CIDR format and should be IPv4 or IPv6, + for example "10.0.0.0/8" or "fd00::/8". + items: + description: CIDR is an IP address range in CIDR + notation (for example, "10.0.0.0/8" or "fd00::/8"). + maxLength: 43 + minLength: 1 + type: string + x-kubernetes-validations: + - message: value must be a valid CIDR network address + rule: isCIDR(self) + maxItems: 32 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - rule: self.all(x, self.exists_one(y, x == y)) + type: object + x-kubernetes-validations: + - message: apiServerInternalIPs list is required once + set + rule: '!has(oldSelf.apiServerInternalIPs) || has(self.apiServerInternalIPs)' + - message: ingressIPs list is required once set + rule: '!has(oldSelf.ingressIPs) || has(self.ingressIPs)' + ovirt: + description: Ovirt contains settings specific to the oVirt + infrastructure provider. + type: object + powervs: + description: PowerVS contains settings specific to the + IBM Power Systems Virtual Servers infrastructure provider. + properties: + serviceEndpoints: + description: |- + serviceEndpoints is a list of custom endpoints which will override the default + service endpoints of a Power VS service. + items: + description: |- + PowervsServiceEndpoint stores the configuration of a custom url to + override existing defaults of PowerVS Services. + properties: + name: + description: |- + name is the name of the Power VS service. + Few of the services are + IAM - https://cloud.ibm.com/apidocs/iam-identity-token-api + ResourceController - https://cloud.ibm.com/apidocs/resource-controller/resource-controller + Power Cloud - https://cloud.ibm.com/apidocs/power-cloud + pattern: ^[a-z0-9-]+$ + type: string + url: + description: |- + url is fully qualified URI with scheme https, that overrides the default generated + endpoint for a client. + This must be provided and cannot be empty. + format: uri + pattern: ^https:// + type: string + required: + - name + - url + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + type: object + type: + description: |- + type is the underlying infrastructure provider for the cluster. This + value controls whether infrastructure automation such as service load + balancers, dynamic volume provisioning, machine creation and deletion, and + other integrations are enabled. If None, no infrastructure automation is + enabled. Allowed values are "AWS", "Azure", "BareMetal", "GCP", "Libvirt", + "OpenStack", "VSphere", "oVirt", "KubeVirt", "EquinixMetal", "PowerVS", + "AlibabaCloud", "Nutanix" and "None". Individual components may not support all platforms, + and must handle unrecognized platforms as None if they do not support that platform. + enum: + - "" + - AWS + - Azure + - BareMetal + - GCP + - Libvirt + - OpenStack + - None + - VSphere + - oVirt + - IBMCloud + - KubeVirt + - EquinixMetal + - PowerVS + - AlibabaCloud + - Nutanix + - External + type: string + vsphere: + description: VSphere contains settings specific to the + VSphere infrastructure provider. + properties: + apiServerInternalIPs: + description: |- + apiServerInternalIPs are the IP addresses to contact the Kubernetes API + server that can be used by components inside the cluster, like kubelets + using the infrastructure rather than Kubernetes networking. These are the + IPs for a self-hosted load balancer in front of the API servers. + In dual stack clusters this list contains two IP addresses, one from IPv4 + family and one from IPv6. + In single stack clusters a single IP address is expected. + When omitted, values from the status.apiServerInternalIPs will be used. + Once set, the list cannot be completely removed (but its second entry can). + items: + description: IP is an IP address (for example, "10.0.0.0" + or "fd00::"). + maxLength: 39 + minLength: 1 + type: string + x-kubernetes-validations: + - message: value must be a valid IP address + rule: isIP(self) + maxItems: 2 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - message: apiServerInternalIPs must contain at most + one IPv4 address and at most one IPv6 address + rule: 'size(self) == 2 && isIP(self[0]) && isIP(self[1]) + ? ip(self[0]).family() != ip(self[1]).family() + : true' + failureDomains: + description: |- + failureDomains contains the definition of region, zone and the vCenter topology. + If this is omitted failure domains (regions and zones) will not be used. + items: + description: VSpherePlatformFailureDomainSpec holds + the region and zone failure domain and the vCenter + topology of that failure domain. + properties: + name: + description: |- + name defines the arbitrary but unique name + of a failure domain. + maxLength: 256 + minLength: 1 + type: string + region: + description: |- + region defines the name of a region tag that will + be attached to a vCenter datacenter. The tag + category in vCenter must be named openshift-region. + maxLength: 80 + minLength: 1 + type: string + regionAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + enum: + - HostGroup + - ComputeCluster + - Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type + must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' + server: + description: server is the fully-qualified domain + name or the IP address of the vCenter server. + maxLength: 255 + minLength: 1 + type: string + topology: + description: Topology describes a given failure + domain using vSphere constructs + properties: + computeCluster: + description: |- + computeCluster the absolute path of the vCenter cluster + in which virtual machine will be located. + The absolute path is of the form //host/. + The maximum length of the path is 2048 characters. + maxLength: 2048 + pattern: ^/.*?/host/.*? + type: string + datacenter: + description: |- + datacenter is the name of vCenter datacenter in which virtual machines will be located. + The maximum length of the datacenter name is 80 characters. + maxLength: 80 + type: string + datastore: + description: |- + datastore is the absolute path of the datastore in which the + virtual machine is located. + The absolute path is of the form //datastore/ + The maximum length of the path is 2048 characters. + maxLength: 2048 + pattern: ^/.*?/datastore/.*? + type: string + folder: + description: |- + folder is the absolute path of the folder where + virtual machines are located. The absolute path + is of the form //vm/. + The maximum length of the path is 2048 characters. + maxLength: 2048 + pattern: ^/.*?/vm/.*? + type: string + networks: + description: |- + networks is the list of port group network names within this failure domain. + If feature gate VSphereMultiNetworks is enabled, up to 10 network adapters may be defined. + 10 is the maximum number of virtual network devices which may be attached to a VM as defined by: + https://configmax.esp.vmware.com/guest?vmwareproduct=vSphere&release=vSphere%208.0&categories=1-0 + The available networks (port groups) can be listed using + `govc ls 'network/*'` + Networks should be in the form of an absolute path: + //network/. + items: + type: string + minItems: 1 + type: array + x-kubernetes-list-type: atomic + resourcePool: + description: |- + resourcePool is the absolute path of the resource pool where virtual machines will be + created. The absolute path is of the form //host//Resources/. + The maximum length of the path is 2048 characters. + maxLength: 2048 + pattern: ^/.*?/host/.*?/Resources.* + type: string + required: + - computeCluster + - datacenter + - datastore + - networks + type: object + zone: + description: |- + zone defines the name of a zone tag that will + be attached to a vCenter cluster. The tag + category in vCenter must be named openshift-zone. + maxLength: 80 + minLength: 1 + type: string + zoneAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + enum: + - HostGroup + - ComputeCluster + - Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type + must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' + required: + - name + - region + - server + - topology + - zone + type: object + x-kubernetes-validations: + - message: when zoneAffinity type is HostGroup, + regionAffinity type must be ComputeCluster + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''HostGroup'' ? has(self.regionAffinity) + && self.regionAffinity.type == ''ComputeCluster'' + : true' + - message: when zoneAffinity type is ComputeCluster, + regionAffinity type must be Datacenter + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''ComputeCluster'' ? has(self.regionAffinity) + && self.regionAffinity.type == ''Datacenter'' + : true' + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + ingressIPs: + description: |- + ingressIPs are the external IPs which route to the default ingress + controller. The IPs are suitable targets of a wildcard DNS record used to + resolve default route host names. + In dual stack clusters this list contains two IP addresses, one from IPv4 + family and one from IPv6. + In single stack clusters a single IP address is expected. + When omitted, values from the status.ingressIPs will be used. + Once set, the list cannot be completely removed (but its second entry can). + items: + description: IP is an IP address (for example, "10.0.0.0" + or "fd00::"). + maxLength: 39 + minLength: 1 + type: string + x-kubernetes-validations: + - message: value must be a valid IP address + rule: isIP(self) + maxItems: 2 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - message: ingressIPs must contain at most one IPv4 + address and at most one IPv6 address + rule: 'size(self) == 2 && isIP(self[0]) && isIP(self[1]) + ? ip(self[0]).family() != ip(self[1]).family() + : true' + machineNetworks: + description: |- + machineNetworks are IP networks used to connect all the OpenShift cluster + nodes. Each network is provided in the CIDR format and should be IPv4 or IPv6, + for example "10.0.0.0/8" or "fd00::/8". + items: + description: CIDR is an IP address range in CIDR + notation (for example, "10.0.0.0/8" or "fd00::/8"). + maxLength: 43 + minLength: 1 + type: string + x-kubernetes-validations: + - message: value must be a valid CIDR network address + rule: isCIDR(self) + maxItems: 32 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - rule: self.all(x, self.exists_one(y, x == y)) + nodeNetworking: + description: |- + nodeNetworking contains the definition of internal and external network constraints for + assigning the node's networking. + If this field is omitted, networking defaults to the legacy + address selection behavior which is to only support a single address and + return the first one found. + properties: + external: + description: external represents the network configuration + of the node that is externally routable. + properties: + excludeNetworkSubnetCidr: + description: |- + excludeNetworkSubnetCidr IP addresses in subnet ranges will be excluded when selecting + the IP address from the VirtualMachine's VM for use in the status.addresses fields. + items: + type: string + type: array + x-kubernetes-list-type: atomic + network: + description: |- + network VirtualMachine's VM Network names that will be used to when searching + for status.addresses fields. Note that if internal.networkSubnetCIDR and + external.networkSubnetCIDR are not set, then the vNIC associated to this network must + only have a single IP address assigned to it. + The available networks (port groups) can be listed using + `govc ls 'network/*'` + type: string + networkSubnetCidr: + description: |- + networkSubnetCidr IP address on VirtualMachine's network interfaces included in the fields' CIDRs + that will be used in respective status.addresses fields. + items: + type: string + type: array + x-kubernetes-list-type: set + type: object + internal: + description: internal represents the network configuration + of the node that is routable only within the + cluster. + properties: + excludeNetworkSubnetCidr: + description: |- + excludeNetworkSubnetCidr IP addresses in subnet ranges will be excluded when selecting + the IP address from the VirtualMachine's VM for use in the status.addresses fields. + items: + type: string + type: array + x-kubernetes-list-type: atomic + network: + description: |- + network VirtualMachine's VM Network names that will be used to when searching + for status.addresses fields. Note that if internal.networkSubnetCIDR and + external.networkSubnetCIDR are not set, then the vNIC associated to this network must + only have a single IP address assigned to it. + The available networks (port groups) can be listed using + `govc ls 'network/*'` + type: string + networkSubnetCidr: + description: |- + networkSubnetCidr IP address on VirtualMachine's network interfaces included in the fields' CIDRs + that will be used in respective status.addresses fields. + items: + type: string + type: array + x-kubernetes-list-type: set + type: object + type: object + vcenters: + description: |- + vcenters holds the connection details for services to communicate with vCenter. + Currently, only a single vCenter is supported, but in tech preview 3 vCenters are supported. + Once the cluster has been installed, you are unable to change the current number of defined + vCenters except in the case where the cluster has been upgraded from a version of OpenShift + where the vsphere platform spec was not present. You may make modifications to the existing + vCenters that are defined in the vcenters list in order to match with any added or modified + failure domains. + items: + description: |- + VSpherePlatformVCenterSpec stores the vCenter connection fields. + This is used by the vSphere CCM. + properties: + datacenters: + description: |- + The vCenter Datacenters in which the RHCOS + vm guests are located. This field will + be used by the Cloud Controller Manager. + Each datacenter listed here should be used within + a topology. + items: + type: string + minItems: 1 + type: array + x-kubernetes-list-type: set + port: + description: |- + port is the TCP port that will be used to communicate to + the vCenter endpoint. + When omitted, this means the user has no opinion and + it is up to the platform to choose a sensible default, + which is subject to change over time. + format: int32 + maximum: 32767 + minimum: 1 + type: integer + server: + description: server is the fully-qualified domain + name or the IP address of the vCenter server. + maxLength: 255 + type: string + required: + - datacenters + - server + type: object + minItems: 0 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - message: vcenters cannot be added or removed once + set + rule: 'size(self) != size(oldSelf) ? size(oldSelf) + == 0 && size(self) < 2 : true' + type: object + x-kubernetes-validations: + - message: apiServerInternalIPs list is required once + set + rule: '!has(oldSelf.apiServerInternalIPs) || has(self.apiServerInternalIPs)' + - message: ingressIPs list is required once set + rule: '!has(oldSelf.ingressIPs) || has(self.ingressIPs)' + - message: vcenters can have at most 1 item when configured + post-install + rule: '!has(oldSelf.vcenters) && has(self.vcenters) + ? size(self.vcenters) < 2 : true' + type: object + x-kubernetes-validations: + - message: vcenters can have at most 1 item when configured + post-install + rule: '!has(oldSelf.vsphere) && has(self.vsphere) ? size(self.vsphere.vcenters) + < 2 : true' + type: object + status: + description: status holds observed values from the cluster. They + may not be overridden. + properties: + apiServerInternalURI: + description: |- + apiServerInternalURL is a valid URI with scheme 'https', + address and optionally a port (defaulting to 443). apiServerInternalURL can be used by components + like kubelets, to contact the Kubernetes API server using the + infrastructure provider rather than Kubernetes networking. + type: string + apiServerURL: + description: |- + apiServerURL is a valid URI with scheme 'https', address and + optionally a port (defaulting to 443). apiServerURL can be used by components like the web console + to tell users where to find the Kubernetes API. + type: string + controlPlaneTopology: + default: HighlyAvailable + description: |- + controlPlaneTopology expresses the expectations for operands that normally run on control nodes. + The default is 'HighlyAvailable', which represents the behavior operators have in a "normal" cluster. + The 'SingleReplica' mode will be used in single-node deployments + and the operators should not configure the operand for highly-available operation + The 'External' mode indicates that the control plane is hosted externally to the cluster and that + its components are not visible within the cluster. + enum: + - HighlyAvailable + - SingleReplica + - External + type: string + cpuPartitioning: + default: None + description: |- + cpuPartitioning expresses if CPU partitioning is a currently enabled feature in the cluster. + CPU Partitioning means that this cluster can support partitioning workloads to specific CPU Sets. + Valid values are "None" and "AllNodes". When omitted, the default value is "None". + The default value of "None" indicates that no nodes will be setup with CPU partitioning. + The "AllNodes" value indicates that all nodes have been setup with CPU partitioning, + and can then be further configured via the PerformanceProfile API. + enum: + - None + - AllNodes + type: string + etcdDiscoveryDomain: + description: |- + etcdDiscoveryDomain is the domain used to fetch the SRV records for discovering + etcd servers and clients. + For more info: https://github.com/etcd-io/etcd/blob/329be66e8b3f9e2e6af83c123ff89297e49ebd15/Documentation/op-guide/clustering.md#dns-discovery + deprecated: as of 4.7, this field is no longer set or honored. It will be removed in a future release. + type: string + infrastructureName: + description: |- + infrastructureName uniquely identifies a cluster with a human friendly name. + Once set it should not be changed. Must be of max length 27 and must have only + alphanumeric or hyphen characters. + type: string + infrastructureTopology: + default: HighlyAvailable + description: |- + infrastructureTopology expresses the expectations for infrastructure services that do not run on control + plane nodes, usually indicated by a node selector for a `role` value + other than `master`. + The default is 'HighlyAvailable', which represents the behavior operators have in a "normal" cluster. + The 'SingleReplica' mode will be used in single-node deployments + and the operators should not configure the operand for highly-available operation + NOTE: External topology mode is not applicable for this field. + enum: + - HighlyAvailable + - SingleReplica + type: string + platform: + description: |- + platform is the underlying infrastructure provider for the cluster. + + Deprecated: Use platformStatus.type instead. + enum: + - "" + - AWS + - Azure + - BareMetal + - GCP + - Libvirt + - OpenStack + - None + - VSphere + - oVirt + - IBMCloud + - KubeVirt + - EquinixMetal + - PowerVS + - AlibabaCloud + - Nutanix + - External + type: string + platformStatus: + description: |- + platformStatus holds status information specific to the underlying + infrastructure provider. + properties: + alibabaCloud: + description: AlibabaCloud contains settings specific to + the Alibaba Cloud infrastructure provider. + properties: + region: + description: region specifies the region for Alibaba + Cloud resources created for the cluster. + pattern: ^[0-9A-Za-z-]+$ + type: string + resourceGroupID: + description: resourceGroupID is the ID of the resource + group for the cluster. + pattern: ^(rg-[0-9A-Za-z]+)?$ + type: string + resourceTags: + description: resourceTags is a list of additional + tags to apply to Alibaba Cloud resources created + for the cluster. + items: + description: AlibabaCloudResourceTag is the set + of tags to add to apply to resources. + properties: + key: + description: key is the key of the tag. + maxLength: 128 + minLength: 1 + type: string + value: + description: value is the value of the tag. + maxLength: 128 + minLength: 1 + type: string + required: + - key + - value + type: object + maxItems: 20 + type: array + x-kubernetes-list-map-keys: + - key + x-kubernetes-list-type: map + required: + - region + type: object + aws: + description: AWS contains settings specific to the Amazon + Web Services infrastructure provider. + properties: + region: + description: region holds the default AWS region for + new AWS resources created by the cluster. + type: string + resourceTags: + description: |- + resourceTags is a list of additional tags to apply to AWS resources created for the cluster. + See https://docs.aws.amazon.com/general/latest/gr/aws_tagging.html for information on tagging AWS resources. + AWS supports a maximum of 50 tags per resource. OpenShift reserves 25 tags for its use, leaving 25 tags + available for the user. + items: + description: AWSResourceTag is a tag to apply to + AWS resources created for the cluster. + properties: + key: + description: key is the key of the tag + maxLength: 128 + minLength: 1 + pattern: ^[0-9A-Za-z_.:/=+-@]+$ + type: string + value: + description: |- + value is the value of the tag. + Some AWS service do not support empty values. Since tags are added to resources in many services, the + length of the tag value must meet the requirements of all services. + maxLength: 256 + minLength: 1 + pattern: ^[0-9A-Za-z_.:/=+-@]+$ + type: string + required: + - key + - value + type: object + maxItems: 25 + type: array + x-kubernetes-list-type: atomic + serviceEndpoints: + description: |- + ServiceEndpoints list contains custom endpoints which will override default + service endpoint of AWS Services. + There must be only one ServiceEndpoint for a service. + items: + description: |- + AWSServiceEndpoint store the configuration of a custom url to + override existing defaults of AWS Services. + properties: + name: + description: |- + name is the name of the AWS service. + The list of all the service names can be found at https://docs.aws.amazon.com/general/latest/gr/aws-service-information.html + This must be provided and cannot be empty. + pattern: ^[a-z0-9-]+$ + type: string + url: + description: |- + url is fully qualified URI with scheme https, that overrides the default generated + endpoint for a client. + This must be provided and cannot be empty. + pattern: ^https:// + type: string + type: object + type: array + x-kubernetes-list-type: atomic + type: object + azure: + description: Azure contains settings specific to the Azure + infrastructure provider. + properties: + armEndpoint: + description: armEndpoint specifies a URL to use for + resource management in non-soverign clouds such + as Azure Stack. + type: string + cloudName: + description: |- + cloudName is the name of the Azure cloud environment which can be used to configure the Azure SDK + with the appropriate Azure API endpoints. + If empty, the value is equal to `AzurePublicCloud`. + enum: + - "" + - AzurePublicCloud + - AzureUSGovernmentCloud + - AzureChinaCloud + - AzureGermanCloud + - AzureStackCloud + type: string + networkResourceGroupName: + description: |- + networkResourceGroupName is the Resource Group for network resources like the Virtual Network and Subnets used by the cluster. + If empty, the value is same as ResourceGroupName. + type: string + resourceGroupName: + description: resourceGroupName is the Resource Group + for new Azure resources created for the cluster. + type: string + resourceTags: + description: |- + resourceTags is a list of additional tags to apply to Azure resources created for the cluster. + See https://docs.microsoft.com/en-us/rest/api/resources/tags for information on tagging Azure resources. + Due to limitations on Automation, Content Delivery Network, DNS Azure resources, a maximum of 15 tags + may be applied. OpenShift reserves 5 tags for internal use, allowing 10 tags for user configuration. + items: + description: AzureResourceTag is a tag to apply + to Azure resources created for the cluster. + properties: + key: + description: |- + key is the key part of the tag. A tag key can have a maximum of 128 characters and cannot be empty. Key + must begin with a letter, end with a letter, number or underscore, and must contain only alphanumeric + characters and the following special characters `_ . -`. + maxLength: 128 + minLength: 1 + pattern: ^[a-zA-Z]([0-9A-Za-z_.-]*[0-9A-Za-z_])?$ + type: string + value: + description: |- + value is the value part of the tag. A tag value can have a maximum of 256 characters and cannot be empty. Value + must contain only alphanumeric characters and the following special characters `_ + , - . / : ; < = > ? @`. + maxLength: 256 + minLength: 1 + pattern: ^[0-9A-Za-z_.=+-@]+$ + type: string + required: + - key + - value + type: object + maxItems: 10 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - message: resourceTags are immutable and may only + be configured during installation + rule: self.all(x, x in oldSelf) && oldSelf.all(x, + x in self) + type: object + x-kubernetes-validations: + - message: resourceTags may only be configured during + installation + rule: '!has(oldSelf.resourceTags) && !has(self.resourceTags) + || has(oldSelf.resourceTags) && has(self.resourceTags)' + baremetal: + description: BareMetal contains settings specific to the + BareMetal platform. + properties: + apiServerInternalIP: + description: |- + apiServerInternalIP is an IP address to contact the Kubernetes API server that can be used + by components inside the cluster, like kubelets using the infrastructure rather + than Kubernetes networking. It is the IP that the Infrastructure.status.apiServerInternalURI + points to. It is the IP for a self-hosted load balancer in front of the API servers. + + Deprecated: Use APIServerInternalIPs instead. + type: string + apiServerInternalIPs: + description: |- + apiServerInternalIPs are the IP addresses to contact the Kubernetes API + server that can be used by components inside the cluster, like kubelets + using the infrastructure rather than Kubernetes networking. These are the + IPs for a self-hosted load balancer in front of the API servers. In dual + stack clusters this list contains two IPs otherwise only one. + format: ip + items: + type: string + maxItems: 2 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - message: apiServerInternalIPs must contain at most + one IPv4 address and at most one IPv6 address + rule: 'self == oldSelf || (size(self) == 2 && isIP(self[0]) + && isIP(self[1]) ? ip(self[0]).family() != ip(self[1]).family() + : true)' + ingressIP: + description: |- + ingressIP is an external IP which routes to the default ingress controller. + The IP is a suitable target of a wildcard DNS record used to resolve default route host names. + + Deprecated: Use IngressIPs instead. + type: string + ingressIPs: + description: |- + ingressIPs are the external IPs which route to the default ingress + controller. The IPs are suitable targets of a wildcard DNS record used to + resolve default route host names. In dual stack clusters this list + contains two IPs otherwise only one. + format: ip + items: + type: string + maxItems: 2 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - message: ingressIPs must contain at most one IPv4 + address and at most one IPv6 address + rule: 'self == oldSelf || (size(self) == 2 && isIP(self[0]) + && isIP(self[1]) ? ip(self[0]).family() != ip(self[1]).family() + : true)' + machineNetworks: + description: machineNetworks are IP networks used + to connect all the OpenShift cluster nodes. + items: + description: CIDR is an IP address range in CIDR + notation (for example, "10.0.0.0/8" or "fd00::/8"). + maxLength: 43 + minLength: 1 + type: string + x-kubernetes-validations: + - message: value must be a valid CIDR network address + rule: isCIDR(self) + maxItems: 32 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - rule: self.all(x, self.exists_one(y, x == y)) + nodeDNSIP: + description: |- + nodeDNSIP is the IP address for the internal DNS used by the + nodes. Unlike the one managed by the DNS operator, `NodeDNSIP` + provides name resolution for the nodes themselves. There is no DNS-as-a-service for + BareMetal deployments. In order to minimize necessary changes to the + datacenter DNS, a DNS service is hosted as a static pod to serve those hostnames + to the nodes in the cluster. + type: string + type: object + equinixMetal: + description: EquinixMetal contains settings specific to + the Equinix Metal infrastructure provider. + properties: + apiServerInternalIP: + description: |- + apiServerInternalIP is an IP address to contact the Kubernetes API server that can be used + by components inside the cluster, like kubelets using the infrastructure rather + than Kubernetes networking. It is the IP that the Infrastructure.status.apiServerInternalURI + points to. It is the IP for a self-hosted load balancer in front of the API servers. + type: string + ingressIP: + description: |- + ingressIP is an external IP which routes to the default ingress controller. + The IP is a suitable target of a wildcard DNS record used to resolve default route host names. + type: string + type: object + external: + description: External contains settings specific to the + generic External infrastructure provider. + properties: + cloudControllerManager: + description: |- + cloudControllerManager contains settings specific to the external Cloud Controller Manager (a.k.a. CCM or CPI). + When omitted, new nodes will be not tainted + and no extra initialization from the cloud controller manager is expected. + properties: + state: + description: |- + state determines whether or not an external Cloud Controller Manager is expected to + be installed within the cluster. + https://kubernetes.io/docs/tasks/administer-cluster/running-cloud-controller/#running-cloud-controller-manager + + Valid values are "External", "None" and omitted. + When set to "External", new nodes will be tainted as uninitialized when created, + preventing them from running workloads until they are initialized by the cloud controller manager. + When omitted or set to "None", new nodes will be not tainted + and no extra initialization from the cloud controller manager is expected. + enum: + - "" + - External + - None + type: string + x-kubernetes-validations: + - message: state is immutable once set + rule: self == oldSelf + type: object + x-kubernetes-validations: + - message: state may not be added or removed once + set + rule: (has(self.state) == has(oldSelf.state)) || + (!has(oldSelf.state) && self.state != "External") + type: object + x-kubernetes-validations: + - message: cloudControllerManager may not be added or + removed once set + rule: has(self.cloudControllerManager) == has(oldSelf.cloudControllerManager) + gcp: + description: GCP contains settings specific to the Google + Cloud Platform infrastructure provider. + properties: + projectID: + description: resourceGroupName is the Project ID for + new GCP resources created for the cluster. + type: string + region: + description: region holds the region for new GCP resources + created for the cluster. + type: string + type: object + ibmcloud: + description: IBMCloud contains settings specific to the + IBMCloud infrastructure provider. + properties: + cisInstanceCRN: + description: |- + CISInstanceCRN is the CRN of the Cloud Internet Services instance managing + the DNS zone for the cluster's base domain + type: string + dnsInstanceCRN: + description: |- + DNSInstanceCRN is the CRN of the DNS Services instance managing the DNS zone + for the cluster's base domain + type: string + location: + description: Location is where the cluster has been + deployed + type: string + providerType: + description: ProviderType indicates the type of cluster + that was created + type: string + resourceGroupName: + description: ResourceGroupName is the Resource Group + for new IBMCloud resources created for the cluster. + type: string + serviceEndpoints: + description: |- + serviceEndpoints is a list of custom endpoints which will override the default + service endpoints of an IBM Cloud service. These endpoints are consumed by + components within the cluster to reach the respective IBM Cloud Services. + items: + description: |- + IBMCloudServiceEndpoint stores the configuration of a custom url to + override existing defaults of IBM Cloud Services. + properties: + name: + description: |- + name is the name of the IBM Cloud service. + Possible values are: CIS, COS, COSConfig, DNSServices, GlobalCatalog, GlobalSearch, GlobalTagging, HyperProtect, IAM, KeyProtect, ResourceController, ResourceManager, or VPC. + For example, the IBM Cloud Private IAM service could be configured with the + service `name` of `IAM` and `url` of `https://private.iam.cloud.ibm.com` + Whereas the IBM Cloud Private VPC service for US South (Dallas) could be configured + with the service `name` of `VPC` and `url` of `https://us.south.private.iaas.cloud.ibm.com` + enum: + - CIS + - COS + - COSConfig + - DNSServices + - GlobalCatalog + - GlobalSearch + - GlobalTagging + - HyperProtect + - IAM + - KeyProtect + - ResourceController + - ResourceManager + - VPC + type: string + url: + description: |- + url is fully qualified URI with scheme https, that overrides the default generated + endpoint for a client. + This must be provided and cannot be empty. + type: string + x-kubernetes-validations: + - message: url must be a valid absolute URL + rule: isURL(self) + required: + - name + - url + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + type: object + kubevirt: + description: Kubevirt contains settings specific to the + kubevirt infrastructure provider. + properties: + apiServerInternalIP: + description: |- + apiServerInternalIP is an IP address to contact the Kubernetes API server that can be used + by components inside the cluster, like kubelets using the infrastructure rather + than Kubernetes networking. It is the IP that the Infrastructure.status.apiServerInternalURI + points to. It is the IP for a self-hosted load balancer in front of the API servers. + type: string + ingressIP: + description: |- + ingressIP is an external IP which routes to the default ingress controller. + The IP is a suitable target of a wildcard DNS record used to resolve default route host names. + type: string + type: object + nutanix: + description: Nutanix contains settings specific to the + Nutanix infrastructure provider. + properties: + apiServerInternalIP: + description: |- + apiServerInternalIP is an IP address to contact the Kubernetes API server that can be used + by components inside the cluster, like kubelets using the infrastructure rather + than Kubernetes networking. It is the IP that the Infrastructure.status.apiServerInternalURI + points to. It is the IP for a self-hosted load balancer in front of the API servers. + + Deprecated: Use APIServerInternalIPs instead. + type: string + apiServerInternalIPs: + description: |- + apiServerInternalIPs are the IP addresses to contact the Kubernetes API + server that can be used by components inside the cluster, like kubelets + using the infrastructure rather than Kubernetes networking. These are the + IPs for a self-hosted load balancer in front of the API servers. In dual + stack clusters this list contains two IPs otherwise only one. + format: ip + items: + type: string + maxItems: 2 + type: array + x-kubernetes-list-type: set + x-kubernetes-validations: + - message: apiServerInternalIPs must contain at most + one IPv4 address and at most one IPv6 address + rule: 'self == oldSelf || (size(self) == 2 && isIP(self[0]) + && isIP(self[1]) ? ip(self[0]).family() != ip(self[1]).family() + : true)' + ingressIP: + description: |- + ingressIP is an external IP which routes to the default ingress controller. + The IP is a suitable target of a wildcard DNS record used to resolve default route host names. + + Deprecated: Use IngressIPs instead. + type: string + ingressIPs: + description: |- + ingressIPs are the external IPs which route to the default ingress + controller. The IPs are suitable targets of a wildcard DNS record used to + resolve default route host names. In dual stack clusters this list + contains two IPs otherwise only one. + format: ip + items: + type: string + maxItems: 2 + type: array + x-kubernetes-list-type: set + x-kubernetes-validations: + - message: ingressIPs must contain at most one IPv4 + address and at most one IPv6 address + rule: 'self == oldSelf || (size(self) == 2 && isIP(self[0]) + && isIP(self[1]) ? ip(self[0]).family() != ip(self[1]).family() + : true)' + type: object + openstack: + description: OpenStack contains settings specific to the + OpenStack infrastructure provider. + properties: + apiServerInternalIP: + description: |- + apiServerInternalIP is an IP address to contact the Kubernetes API server that can be used + by components inside the cluster, like kubelets using the infrastructure rather + than Kubernetes networking. It is the IP that the Infrastructure.status.apiServerInternalURI + points to. It is the IP for a self-hosted load balancer in front of the API servers. + + Deprecated: Use APIServerInternalIPs instead. + type: string + apiServerInternalIPs: + description: |- + apiServerInternalIPs are the IP addresses to contact the Kubernetes API + server that can be used by components inside the cluster, like kubelets + using the infrastructure rather than Kubernetes networking. These are the + IPs for a self-hosted load balancer in front of the API servers. In dual + stack clusters this list contains two IPs otherwise only one. + format: ip + items: + type: string + maxItems: 2 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - message: apiServerInternalIPs must contain at most + one IPv4 address and at most one IPv6 address + rule: 'self == oldSelf || (size(self) == 2 && isIP(self[0]) + && isIP(self[1]) ? ip(self[0]).family() != ip(self[1]).family() + : true)' + cloudName: + description: |- + cloudName is the name of the desired OpenStack cloud in the + client configuration file (`clouds.yaml`). + type: string + ingressIP: + description: |- + ingressIP is an external IP which routes to the default ingress controller. + The IP is a suitable target of a wildcard DNS record used to resolve default route host names. + + Deprecated: Use IngressIPs instead. + type: string + ingressIPs: + description: |- + ingressIPs are the external IPs which route to the default ingress + controller. The IPs are suitable targets of a wildcard DNS record used to + resolve default route host names. In dual stack clusters this list + contains two IPs otherwise only one. + format: ip + items: + type: string + maxItems: 2 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - message: ingressIPs must contain at most one IPv4 + address and at most one IPv6 address + rule: 'self == oldSelf || (size(self) == 2 && isIP(self[0]) + && isIP(self[1]) ? ip(self[0]).family() != ip(self[1]).family() + : true)' + loadBalancer: + default: + type: OpenShiftManagedDefault + description: loadBalancer defines how the load balancer + used by the cluster is configured. + properties: + type: + default: OpenShiftManagedDefault + description: |- + type defines the type of load balancer used by the cluster on OpenStack platform + which can be a user-managed or openshift-managed load balancer + that is to be used for the OpenShift API and Ingress endpoints. + When set to OpenShiftManagedDefault the static pods in charge of API and Ingress traffic load-balancing + defined in the machine config operator will be deployed. + When set to UserManaged these static pods will not be deployed and it is expected that + the load balancer is configured out of band by the deployer. + When omitted, this means no opinion and the platform is left to choose a reasonable default. + The default value is OpenShiftManagedDefault. + enum: + - OpenShiftManagedDefault + - UserManaged + type: string + x-kubernetes-validations: + - message: type is immutable once set + rule: oldSelf == '' || self == oldSelf + type: object + machineNetworks: + description: machineNetworks are IP networks used + to connect all the OpenShift cluster nodes. + items: + description: CIDR is an IP address range in CIDR + notation (for example, "10.0.0.0/8" or "fd00::/8"). + maxLength: 43 + minLength: 1 + type: string + x-kubernetes-validations: + - message: value must be a valid CIDR network address + rule: isCIDR(self) + maxItems: 32 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - rule: self.all(x, self.exists_one(y, x == y)) + nodeDNSIP: + description: |- + nodeDNSIP is the IP address for the internal DNS used by the + nodes. Unlike the one managed by the DNS operator, `NodeDNSIP` + provides name resolution for the nodes themselves. There is no DNS-as-a-service for + OpenStack deployments. In order to minimize necessary changes to the + datacenter DNS, a DNS service is hosted as a static pod to serve those hostnames + to the nodes in the cluster. + type: string + type: object + ovirt: + description: Ovirt contains settings specific to the oVirt + infrastructure provider. + properties: + apiServerInternalIP: + description: |- + apiServerInternalIP is an IP address to contact the Kubernetes API server that can be used + by components inside the cluster, like kubelets using the infrastructure rather + than Kubernetes networking. It is the IP that the Infrastructure.status.apiServerInternalURI + points to. It is the IP for a self-hosted load balancer in front of the API servers. + + Deprecated: Use APIServerInternalIPs instead. + type: string + apiServerInternalIPs: + description: |- + apiServerInternalIPs are the IP addresses to contact the Kubernetes API + server that can be used by components inside the cluster, like kubelets + using the infrastructure rather than Kubernetes networking. These are the + IPs for a self-hosted load balancer in front of the API servers. In dual + stack clusters this list contains two IPs otherwise only one. + format: ip + items: + type: string + maxItems: 2 + type: array + x-kubernetes-list-type: set + x-kubernetes-validations: + - message: apiServerInternalIPs must contain at most + one IPv4 address and at most one IPv6 address + rule: 'self == oldSelf || (size(self) == 2 && isIP(self[0]) + && isIP(self[1]) ? ip(self[0]).family() != ip(self[1]).family() + : true)' + ingressIP: + description: |- + ingressIP is an external IP which routes to the default ingress controller. + The IP is a suitable target of a wildcard DNS record used to resolve default route host names. + + Deprecated: Use IngressIPs instead. + type: string + ingressIPs: + description: |- + ingressIPs are the external IPs which route to the default ingress + controller. The IPs are suitable targets of a wildcard DNS record used to + resolve default route host names. In dual stack clusters this list + contains two IPs otherwise only one. + format: ip + items: + type: string + maxItems: 2 + type: array + x-kubernetes-list-type: set + x-kubernetes-validations: + - message: ingressIPs must contain at most one IPv4 + address and at most one IPv6 address + rule: 'self == oldSelf || (size(self) == 2 && isIP(self[0]) + && isIP(self[1]) ? ip(self[0]).family() != ip(self[1]).family() + : true)' + nodeDNSIP: + description: 'deprecated: as of 4.6, this field is + no longer set or honored. It will be removed in + a future release.' + type: string + type: object + powervs: + description: PowerVS contains settings specific to the + Power Systems Virtual Servers infrastructure provider. + properties: + cisInstanceCRN: + description: |- + CISInstanceCRN is the CRN of the Cloud Internet Services instance managing + the DNS zone for the cluster's base domain + type: string + dnsInstanceCRN: + description: |- + DNSInstanceCRN is the CRN of the DNS Services instance managing the DNS zone + for the cluster's base domain + type: string + region: + description: region holds the default Power VS region + for new Power VS resources created by the cluster. + type: string + resourceGroup: + description: |- + resourceGroup is the resource group name for new IBMCloud resources created for a cluster. + The resource group specified here will be used by cluster-image-registry-operator to set up a COS Instance in IBMCloud for the cluster registry. + More about resource groups can be found here: https://cloud.ibm.com/docs/account?topic=account-rgs. + When omitted, the image registry operator won't be able to configure storage, + which results in the image registry cluster operator not being in an available state. + maxLength: 40 + pattern: ^[a-zA-Z0-9-_ ]+$ + type: string + x-kubernetes-validations: + - message: resourceGroup is immutable once set + rule: oldSelf == '' || self == oldSelf + serviceEndpoints: + description: |- + serviceEndpoints is a list of custom endpoints which will override the default + service endpoints of a Power VS service. + items: + description: |- + PowervsServiceEndpoint stores the configuration of a custom url to + override existing defaults of PowerVS Services. + properties: + name: + description: |- + name is the name of the Power VS service. + Few of the services are + IAM - https://cloud.ibm.com/apidocs/iam-identity-token-api + ResourceController - https://cloud.ibm.com/apidocs/resource-controller/resource-controller + Power Cloud - https://cloud.ibm.com/apidocs/power-cloud + pattern: ^[a-z0-9-]+$ + type: string + url: + description: |- + url is fully qualified URI with scheme https, that overrides the default generated + endpoint for a client. + This must be provided and cannot be empty. + format: uri + pattern: ^https:// + type: string + required: + - name + - url + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + zone: + description: |- + zone holds the default zone for the new Power VS resources created by the cluster. + Note: Currently only single-zone OCP clusters are supported + type: string + type: object + x-kubernetes-validations: + - message: cannot unset resourceGroup once set + rule: '!has(oldSelf.resourceGroup) || has(self.resourceGroup)' + type: + description: |- + type is the underlying infrastructure provider for the cluster. This + value controls whether infrastructure automation such as service load + balancers, dynamic volume provisioning, machine creation and deletion, and + other integrations are enabled. If None, no infrastructure automation is + enabled. Allowed values are "AWS", "Azure", "BareMetal", "GCP", "Libvirt", + "OpenStack", "VSphere", "oVirt", "EquinixMetal", "PowerVS", "AlibabaCloud", "Nutanix" and "None". + Individual components may not support all platforms, and must handle + unrecognized platforms as None if they do not support that platform. + + This value will be synced with to the `status.platform` and `status.platformStatus.type`. + Currently this value cannot be changed once set. + enum: + - "" + - AWS + - Azure + - BareMetal + - GCP + - Libvirt + - OpenStack + - None + - VSphere + - oVirt + - IBMCloud + - KubeVirt + - EquinixMetal + - PowerVS + - AlibabaCloud + - Nutanix + - External + type: string + vsphere: + description: VSphere contains settings specific to the + VSphere infrastructure provider. + properties: + apiServerInternalIP: + description: |- + apiServerInternalIP is an IP address to contact the Kubernetes API server that can be used + by components inside the cluster, like kubelets using the infrastructure rather + than Kubernetes networking. It is the IP that the Infrastructure.status.apiServerInternalURI + points to. It is the IP for a self-hosted load balancer in front of the API servers. + + Deprecated: Use APIServerInternalIPs instead. + type: string + apiServerInternalIPs: + description: |- + apiServerInternalIPs are the IP addresses to contact the Kubernetes API + server that can be used by components inside the cluster, like kubelets + using the infrastructure rather than Kubernetes networking. These are the + IPs for a self-hosted load balancer in front of the API servers. In dual + stack clusters this list contains two IPs otherwise only one. + format: ip + items: + type: string + maxItems: 2 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - message: apiServerInternalIPs must contain at most + one IPv4 address and at most one IPv6 address + rule: 'self == oldSelf || (size(self) == 2 && isIP(self[0]) + && isIP(self[1]) ? ip(self[0]).family() != ip(self[1]).family() + : true)' + ingressIP: + description: |- + ingressIP is an external IP which routes to the default ingress controller. + The IP is a suitable target of a wildcard DNS record used to resolve default route host names. + + Deprecated: Use IngressIPs instead. + type: string + ingressIPs: + description: |- + ingressIPs are the external IPs which route to the default ingress + controller. The IPs are suitable targets of a wildcard DNS record used to + resolve default route host names. In dual stack clusters this list + contains two IPs otherwise only one. + format: ip + items: + type: string + maxItems: 2 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - message: ingressIPs must contain at most one IPv4 + address and at most one IPv6 address + rule: 'self == oldSelf || (size(self) == 2 && isIP(self[0]) + && isIP(self[1]) ? ip(self[0]).family() != ip(self[1]).family() + : true)' + machineNetworks: + description: machineNetworks are IP networks used + to connect all the OpenShift cluster nodes. + items: + description: CIDR is an IP address range in CIDR + notation (for example, "10.0.0.0/8" or "fd00::/8"). + maxLength: 43 + minLength: 1 + type: string + x-kubernetes-validations: + - message: value must be a valid CIDR network address + rule: isCIDR(self) + maxItems: 32 + type: array + x-kubernetes-list-type: atomic + x-kubernetes-validations: + - rule: self.all(x, self.exists_one(y, x == y)) + nodeDNSIP: + description: |- + nodeDNSIP is the IP address for the internal DNS used by the + nodes. Unlike the one managed by the DNS operator, `NodeDNSIP` + provides name resolution for the nodes themselves. There is no DNS-as-a-service for + vSphere deployments. In order to minimize necessary changes to the + datacenter DNS, a DNS service is hosted as a static pod to serve those hostnames + to the nodes in the cluster. + type: string + type: object + type: object + type: object + required: + - spec + type: object + x-kubernetes-embedded-resource: true + internalRegistryPullSecret: + description: |- + internalRegistryPullSecret is the pull secret for the internal registry, used by + rpm-ostree to pull images from the internal registry if present + format: byte + nullable: true + type: string + ipFamilies: + description: ipFamilies indicates the IP families in use by the cluster + network + type: string + kubeAPIServerServingCAData: + description: kubeAPIServerServingCAData managed Kubelet to API Server + Cert... Rotated automatically + format: byte + type: string + network: + description: Network contains additional network related information + nullable: true + properties: + mtuMigration: + description: MTUMigration contains the MTU migration configuration. + nullable: true + properties: + machine: + description: Machine contains MTU migration configuration + for the machine's uplink. + properties: + from: + description: From is the MTU to migrate from. + format: int32 + minimum: 0 + type: integer + to: + description: To is the MTU to migrate to. + format: int32 + minimum: 0 + type: integer + type: object + network: + description: Network contains MTU migration configuration + for the default network. + properties: + from: + description: From is the MTU to migrate from. + format: int32 + minimum: 0 + type: integer + to: + description: To is the MTU to migrate to. + format: int32 + minimum: 0 + type: integer + type: object + type: object + required: + - mtuMigration + type: object + networkType: + description: |- + networkType holds the type of network the cluster is using + XXX: this is temporary and will be dropped as soon as possible in favor of a better support + to start network related services the proper way. + Nobody is also changing this once the cluster is up and running the first time, so, disallow + regeneration if this changes. + type: string + osImageURL: + description: OSImageURL is the old-format container image that contains + the OS update payload. + type: string + platform: + description: platform is deprecated, use Infra.Status.PlatformStatus.Type + instead + type: string + proxy: + description: proxy holds the current proxy configuration for the nodes + nullable: true + properties: + httpProxy: + description: httpProxy is the URL of the proxy for HTTP requests. + type: string + httpsProxy: + description: httpsProxy is the URL of the proxy for HTTPS requests. + type: string + noProxy: + description: noProxy is a comma-separated list of hostnames and/or + CIDRs for which the proxy should not be used. + type: string + type: object + pullSecret: + description: |- + pullSecret is the default pull secret that needs to be installed + on all machines. + properties: + apiVersion: + description: API version of the referent. + type: string + fieldPath: + description: |- + If referring to a piece of an object instead of an entire object, this string + should contain a valid JSON/Go field access statement, such as desiredState.manifest.containers[2]. + For example, if the object reference is to a container within a pod, this would take on a value like: + "spec.containers{name}" (where "name" refers to the name of the container that triggered + the event) or if no container name is specified "spec.containers[2]" (container with + index 2 in this pod). This syntax is chosen only to have some well-defined way of + referencing a part of an object. + type: string + kind: + description: |- + Kind of the referent. + More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + type: string + name: + description: |- + Name of the referent. + More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names + type: string + namespace: + description: |- + Namespace of the referent. + More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/ + type: string + resourceVersion: + description: |- + Specific resourceVersion to which this reference is made, if any. + More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#concurrency-control-and-consistency + type: string + uid: + description: |- + UID of the referent. + More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#uids + type: string + type: object + x-kubernetes-map-type: atomic + releaseImage: + description: releaseImage is the image used when installing the cluster + type: string + rootCAData: + description: rootCAData specifies the root CA data + format: byte + type: string + required: + - additionalTrustBundle + - baseOSContainerImage + - cloudProviderCAData + - cloudProviderConfig + - clusterDNSIP + - dns + - images + - infra + - ipFamilies + - kubeAPIServerServingCAData + - network + - proxy + - releaseImage + - rootCAData + type: object + status: + description: ControllerConfigStatus is the status for ControllerConfig + properties: + conditions: + description: conditions represents the latest available observations + of current state. + items: + description: ControllerConfigStatusCondition contains condition + information for ControllerConfigStatus + properties: + lastTransitionTime: + description: lastTransitionTime is the time of the last update + to the current status object. + format: date-time + nullable: true + type: string + message: + description: |- + message provides additional information about the current condition. + This is only to be consumed by humans. + type: string + reason: + description: reason is the reason for the condition's last transition. Reasons + are PascalCase + type: string + status: + description: status of the condition, one of True, False, Unknown. + type: string + type: + description: type specifies the state of the operator's reconciliation + functionality. + type: string + required: + - lastTransitionTime + - status + - type + type: object + type: array + x-kubernetes-list-type: atomic + controllerCertificates: + description: controllerCertificates represents the latest available + observations of the automatically rotating certificates in the MCO. + items: + description: ControllerCertificate contains info about a specific + cert. + properties: + bundleFile: + description: bundleFile is the larger bundle a cert comes from + type: string + notAfter: + description: notAfter is the upper boundary for validity + format: date-time + type: string + notBefore: + description: notBefore is the lower boundary for validity + format: date-time + type: string + signer: + description: signer is the cert Issuer + type: string + subject: + description: subject is the cert subject + type: string + required: + - bundleFile + - signer + - subject + type: object + type: array + x-kubernetes-list-type: atomic + observedGeneration: + description: observedGeneration represents the generation observed + by the controller. + format: int64 + type: integer + type: object + required: + - spec + type: object + served: true + storage: true + subresources: + status: {} diff --git a/machineconfiguration/v1/zz_generated.featuregated-crd-manifests/controllerconfigs.machineconfiguration.openshift.io/VSphereMultiNetworks.yaml b/machineconfiguration/v1/zz_generated.featuregated-crd-manifests/controllerconfigs.machineconfiguration.openshift.io/VSphereMultiNetworks.yaml index e78436374c7..89f6b9b00de 100644 --- a/machineconfiguration/v1/zz_generated.featuregated-crd-manifests/controllerconfigs.machineconfiguration.openshift.io/VSphereMultiNetworks.yaml +++ b/machineconfiguration/v1/zz_generated.featuregated-crd-manifests/controllerconfigs.machineconfiguration.openshift.io/VSphereMultiNetworks.yaml @@ -895,9 +895,9 @@ spec: failureDomains contains the definition of region, zone and the vCenter topology. If this is omitted failure domains (regions and zones) will not be used. items: - description: |- - VSpherePlatformFailureDomainSpec holds the region and zone failure domain and - the vCenter topology of that failure domain. + description: VSpherePlatformFailureDomainSpec holds + the region and zone failure domain and the vCenter + topology of that failure domain. properties: name: description: |- @@ -914,6 +914,61 @@ spec: maxLength: 80 minLength: 1 type: string + regionAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type + must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' server: description: server is the fully-qualified domain name or the IP address of the vCenter server. @@ -995,6 +1050,61 @@ spec: maxLength: 80 minLength: 1 type: string + zoneAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type + must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' required: - name - region @@ -1002,6 +1112,19 @@ spec: - topology - zone type: object + x-kubernetes-validations: + - message: when zoneAffinity type is HostGroup, + regionAffinity type must be ComputeCluster + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''HostGroup'' ? has(self.regionAffinity) + && self.regionAffinity.type == ''ComputeCluster'' + : true' + - message: when zoneAffinity type is ComputeCluster, + regionAffinity type must be Datacenter + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''ComputeCluster'' ? has(self.regionAffinity) + && self.regionAffinity.type == ''Datacenter'' + : true' type: array x-kubernetes-list-map-keys: - name diff --git a/machineconfiguration/v1/zz_generated.featuregated-crd-manifests/controllerconfigs.machineconfiguration.openshift.io/VSphereMultiVCenters.yaml b/machineconfiguration/v1/zz_generated.featuregated-crd-manifests/controllerconfigs.machineconfiguration.openshift.io/VSphereMultiVCenters.yaml index e1eb8633809..deb86827cfc 100644 --- a/machineconfiguration/v1/zz_generated.featuregated-crd-manifests/controllerconfigs.machineconfiguration.openshift.io/VSphereMultiVCenters.yaml +++ b/machineconfiguration/v1/zz_generated.featuregated-crd-manifests/controllerconfigs.machineconfiguration.openshift.io/VSphereMultiVCenters.yaml @@ -895,9 +895,9 @@ spec: failureDomains contains the definition of region, zone and the vCenter topology. If this is omitted failure domains (regions and zones) will not be used. items: - description: |- - VSpherePlatformFailureDomainSpec holds the region and zone failure domain and - the vCenter topology of that failure domain. + description: VSpherePlatformFailureDomainSpec holds + the region and zone failure domain and the vCenter + topology of that failure domain. properties: name: description: |- @@ -914,6 +914,61 @@ spec: maxLength: 80 minLength: 1 type: string + regionAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type + must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' server: description: server is the fully-qualified domain name or the IP address of the vCenter server. @@ -994,6 +1049,61 @@ spec: maxLength: 80 minLength: 1 type: string + zoneAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type + must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' required: - name - region @@ -1001,6 +1111,19 @@ spec: - topology - zone type: object + x-kubernetes-validations: + - message: when zoneAffinity type is HostGroup, + regionAffinity type must be ComputeCluster + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''HostGroup'' ? has(self.regionAffinity) + && self.regionAffinity.type == ''ComputeCluster'' + : true' + - message: when zoneAffinity type is ComputeCluster, + regionAffinity type must be Datacenter + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''ComputeCluster'' ? has(self.regionAffinity) + && self.regionAffinity.type == ''Datacenter'' + : true' type: array x-kubernetes-list-map-keys: - name diff --git a/openapi/generated_openapi/zz_generated.openapi.go b/openapi/generated_openapi/zz_generated.openapi.go index 741a92531b3..4547e59f5fa 100644 --- a/openapi/generated_openapi/zz_generated.openapi.go +++ b/openapi/generated_openapi/zz_generated.openapi.go @@ -387,6 +387,7 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA "github.com/openshift/api/config/v1.UpdateHistory": schema_openshift_api_config_v1_UpdateHistory(ref), "github.com/openshift/api/config/v1.UsernameClaimMapping": schema_openshift_api_config_v1_UsernameClaimMapping(ref), "github.com/openshift/api/config/v1.UsernamePrefix": schema_openshift_api_config_v1_UsernamePrefix(ref), + "github.com/openshift/api/config/v1.VSphereFailureDomainAffinity": schema_openshift_api_config_v1_VSphereFailureDomainAffinity(ref), "github.com/openshift/api/config/v1.VSpherePlatformFailureDomainSpec": schema_openshift_api_config_v1_VSpherePlatformFailureDomainSpec(ref), "github.com/openshift/api/config/v1.VSpherePlatformLoadBalancer": schema_openshift_api_config_v1_VSpherePlatformLoadBalancer(ref), "github.com/openshift/api/config/v1.VSpherePlatformNodeNetworking": schema_openshift_api_config_v1_VSpherePlatformNodeNetworking(ref), @@ -19417,6 +19418,62 @@ func schema_openshift_api_config_v1_UsernamePrefix(ref common.ReferenceCallback) } } +func schema_openshift_api_config_v1_VSphereFailureDomainAffinity(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "VSphereFailureDomainAffinity contains the vCenter cluster vm-host group (virtual machine and host types) and the vm-host affinity rule that together creates a affinity configuration for vm-host based zonal. This configuration within vCenter creates the required association between a failure domain, virtual machines and ESXi hosts to create a vm-host based zone.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "type": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "vmGroup": { + SchemaProps: spec.SchemaProps{ + Description: "vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. This field is required when the VSphereFailureDomain ZoneType is HostGroup", + Type: []string{"string"}, + Format: "", + }, + }, + "hostGroup": { + SchemaProps: spec.SchemaProps{ + Description: "hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. This field is required when the VSphereFailureDomain ZoneType is HostGroup", + Type: []string{"string"}, + Format: "", + }, + }, + "vmHostRule": { + SchemaProps: spec.SchemaProps{ + Description: "vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. This field is required when the VSphereFailureDomain ZoneType is HostGroup", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"type"}, + }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-unions": []interface{}{ + map[string]interface{}{ + "discriminator": "type", + "fields-to-discriminateBy": map[string]interface{}{ + "hostGroup": "HostGroup", + "vmGroup": "VMGroup", + "vmHostRule": "VMHostRule", + }, + }, + }, + }, + }, + }, + } +} + func schema_openshift_api_config_v1_VSpherePlatformFailureDomainSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ @@ -19448,6 +19505,20 @@ func schema_openshift_api_config_v1_VSpherePlatformFailureDomainSpec(ref common. Format: "", }, }, + "regionAffinity": { + SchemaProps: spec.SchemaProps{ + Description: "affinity holds the VMGroup and the HostGroup names in vCenter corresponds to a vm-host group of type Virtual Machine and Host respectively. Is also contains the VMHostRule which is an affinity vm-host rule in vCenter.", + Default: map[string]interface{}{}, + Ref: ref("github.com/openshift/api/config/v1.VSphereFailureDomainAffinity"), + }, + }, + "zoneAffinity": { + SchemaProps: spec.SchemaProps{ + Description: "affinity holds the VMGroup and the HostGroup names in vCenter corresponds to a vm-host group of type Virtual Machine and Host respectively. Is also contains the VMHostRule which is an affinity vm-host rule in vCenter.", + Default: map[string]interface{}{}, + Ref: ref("github.com/openshift/api/config/v1.VSphereFailureDomainAffinity"), + }, + }, "server": { SchemaProps: spec.SchemaProps{ Description: "server is the fully-qualified domain name or the IP address of the vCenter server.", @@ -19468,7 +19539,7 @@ func schema_openshift_api_config_v1_VSpherePlatformFailureDomainSpec(ref common. }, }, Dependencies: []string{ - "github.com/openshift/api/config/v1.VSpherePlatformTopology"}, + "github.com/openshift/api/config/v1.VSphereFailureDomainAffinity", "github.com/openshift/api/config/v1.VSpherePlatformTopology"}, } } @@ -38745,6 +38816,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 3d6013107c5..c634fe9a255 100644 --- a/openapi/openapi.json +++ b/openapi/openapi.json @@ -10546,6 +10546,41 @@ } } }, + "com.github.openshift.api.config.v1.VSphereFailureDomainAffinity": { + "description": "VSphereFailureDomainAffinity contains the vCenter cluster vm-host group (virtual machine and host types) and the vm-host affinity rule that together creates a affinity configuration for vm-host based zonal. This configuration within vCenter creates the required association between a failure domain, virtual machines and ESXi hosts to create a vm-host based zone.", + "type": "object", + "required": [ + "type" + ], + "properties": { + "hostGroup": { + "description": "hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. This field is required when the VSphereFailureDomain ZoneType is HostGroup", + "type": "string" + }, + "type": { + "type": "string", + "default": "" + }, + "vmGroup": { + "description": "vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. This field is required when the VSphereFailureDomain ZoneType is HostGroup", + "type": "string" + }, + "vmHostRule": { + "description": "vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. This field is required when the VSphereFailureDomain ZoneType is HostGroup", + "type": "string" + } + }, + "x-kubernetes-unions": [ + { + "discriminator": "type", + "fields-to-discriminateBy": { + "hostGroup": "HostGroup", + "vmGroup": "VMGroup", + "vmHostRule": "VMHostRule" + } + } + ] + }, "com.github.openshift.api.config.v1.VSpherePlatformFailureDomainSpec": { "description": "VSpherePlatformFailureDomainSpec holds the region and zone failure domain and the vCenter topology of that failure domain.", "type": "object", @@ -10567,6 +10602,11 @@ "type": "string", "default": "" }, + "regionAffinity": { + "description": "affinity holds the VMGroup and the HostGroup names in vCenter corresponds to a vm-host group of type Virtual Machine and Host respectively. Is also contains the VMHostRule which is an affinity vm-host rule in vCenter.", + "default": {}, + "$ref": "#/definitions/com.github.openshift.api.config.v1.VSphereFailureDomainAffinity" + }, "server": { "description": "server is the fully-qualified domain name or the IP address of the vCenter server.", "type": "string", @@ -10581,6 +10621,11 @@ "description": "zone defines the name of a zone tag that will be attached to a vCenter cluster. The tag category in vCenter must be named openshift-zone.", "type": "string", "default": "" + }, + "zoneAffinity": { + "description": "affinity holds the VMGroup and the HostGroup names in vCenter corresponds to a vm-host group of type Virtual Machine and Host respectively. Is also contains the VMHostRule which is an affinity vm-host rule in vCenter.", + "default": {}, + "$ref": "#/definitions/com.github.openshift.api.config.v1.VSphereFailureDomainAffinity" } } }, @@ -22369,6 +22414,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" } } }, diff --git a/payload-manifests/crds/0000_10_config-operator_01_infrastructures-CustomNoUpgrade.crd.yaml b/payload-manifests/crds/0000_10_config-operator_01_infrastructures-CustomNoUpgrade.crd.yaml index 28e7a04c3d8..76ee0050f1e 100644 --- a/payload-manifests/crds/0000_10_config-operator_01_infrastructures-CustomNoUpgrade.crd.yaml +++ b/payload-manifests/crds/0000_10_config-operator_01_infrastructures-CustomNoUpgrade.crd.yaml @@ -608,9 +608,9 @@ spec: failureDomains contains the definition of region, zone and the vCenter topology. If this is omitted failure domains (regions and zones) will not be used. items: - description: |- - VSpherePlatformFailureDomainSpec holds the region and zone failure domain and - the vCenter topology of that failure domain. + description: VSpherePlatformFailureDomainSpec holds the + region and zone failure domain and the vCenter topology + of that failure domain. properties: name: description: |- @@ -627,6 +627,65 @@ spec: maxLength: 80 minLength: 1 type: string + regionAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + enum: + - HostGroup + - ComputeCluster + - Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' server: anyOf: - format: ipv4 @@ -727,6 +786,65 @@ spec: maxLength: 80 minLength: 1 type: string + zoneAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + enum: + - HostGroup + - ComputeCluster + - Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' required: - name - region @@ -734,6 +852,17 @@ spec: - topology - zone type: object + x-kubernetes-validations: + - message: when zoneAffinity type is HostGroup, regionAffinity + type must be ComputeCluster + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''HostGroup'' ? has(self.regionAffinity) && self.regionAffinity.type + == ''ComputeCluster'' : true' + - message: when zoneAffinity type is ComputeCluster, regionAffinity + type must be Datacenter + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''ComputeCluster'' ? has(self.regionAffinity) && + self.regionAffinity.type == ''Datacenter'' : true' type: array x-kubernetes-list-map-keys: - name diff --git a/payload-manifests/crds/0000_10_config-operator_01_infrastructures-Default.crd.yaml b/payload-manifests/crds/0000_10_config-operator_01_infrastructures-Default.crd.yaml index f2f1d4fb836..b5ee9971316 100644 --- a/payload-manifests/crds/0000_10_config-operator_01_infrastructures-Default.crd.yaml +++ b/payload-manifests/crds/0000_10_config-operator_01_infrastructures-Default.crd.yaml @@ -608,9 +608,9 @@ spec: failureDomains contains the definition of region, zone and the vCenter topology. If this is omitted failure domains (regions and zones) will not be used. items: - description: |- - VSpherePlatformFailureDomainSpec holds the region and zone failure domain and - the vCenter topology of that failure domain. + description: VSpherePlatformFailureDomainSpec holds the + region and zone failure domain and the vCenter topology + of that failure domain. properties: name: description: |- @@ -627,6 +627,61 @@ spec: maxLength: 80 minLength: 1 type: string + regionAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' server: anyOf: - format: ipv4 @@ -727,6 +782,61 @@ spec: maxLength: 80 minLength: 1 type: string + zoneAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' required: - name - region @@ -734,6 +844,17 @@ spec: - topology - zone type: object + x-kubernetes-validations: + - message: when zoneAffinity type is HostGroup, regionAffinity + type must be ComputeCluster + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''HostGroup'' ? has(self.regionAffinity) && self.regionAffinity.type + == ''ComputeCluster'' : true' + - message: when zoneAffinity type is ComputeCluster, regionAffinity + type must be Datacenter + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''ComputeCluster'' ? has(self.regionAffinity) && + self.regionAffinity.type == ''Datacenter'' : true' type: array x-kubernetes-list-map-keys: - name diff --git a/payload-manifests/crds/0000_10_config-operator_01_infrastructures-DevPreviewNoUpgrade.crd.yaml b/payload-manifests/crds/0000_10_config-operator_01_infrastructures-DevPreviewNoUpgrade.crd.yaml index e6155bdb923..d1f019d0b8c 100644 --- a/payload-manifests/crds/0000_10_config-operator_01_infrastructures-DevPreviewNoUpgrade.crd.yaml +++ b/payload-manifests/crds/0000_10_config-operator_01_infrastructures-DevPreviewNoUpgrade.crd.yaml @@ -608,9 +608,9 @@ spec: failureDomains contains the definition of region, zone and the vCenter topology. If this is omitted failure domains (regions and zones) will not be used. items: - description: |- - VSpherePlatformFailureDomainSpec holds the region and zone failure domain and - the vCenter topology of that failure domain. + description: VSpherePlatformFailureDomainSpec holds the + region and zone failure domain and the vCenter topology + of that failure domain. properties: name: description: |- @@ -627,6 +627,65 @@ spec: maxLength: 80 minLength: 1 type: string + regionAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + enum: + - HostGroup + - ComputeCluster + - Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' server: anyOf: - format: ipv4 @@ -727,6 +786,65 @@ spec: maxLength: 80 minLength: 1 type: string + zoneAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + enum: + - HostGroup + - ComputeCluster + - Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' required: - name - region @@ -734,6 +852,17 @@ spec: - topology - zone type: object + x-kubernetes-validations: + - message: when zoneAffinity type is HostGroup, regionAffinity + type must be ComputeCluster + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''HostGroup'' ? has(self.regionAffinity) && self.regionAffinity.type + == ''ComputeCluster'' : true' + - message: when zoneAffinity type is ComputeCluster, regionAffinity + type must be Datacenter + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''ComputeCluster'' ? has(self.regionAffinity) && + self.regionAffinity.type == ''Datacenter'' : true' type: array x-kubernetes-list-map-keys: - name diff --git a/payload-manifests/crds/0000_10_config-operator_01_infrastructures-TechPreviewNoUpgrade.crd.yaml b/payload-manifests/crds/0000_10_config-operator_01_infrastructures-TechPreviewNoUpgrade.crd.yaml index 41806e139e4..9fe3f557c2c 100644 --- a/payload-manifests/crds/0000_10_config-operator_01_infrastructures-TechPreviewNoUpgrade.crd.yaml +++ b/payload-manifests/crds/0000_10_config-operator_01_infrastructures-TechPreviewNoUpgrade.crd.yaml @@ -608,9 +608,9 @@ spec: failureDomains contains the definition of region, zone and the vCenter topology. If this is omitted failure domains (regions and zones) will not be used. items: - description: |- - VSpherePlatformFailureDomainSpec holds the region and zone failure domain and - the vCenter topology of that failure domain. + description: VSpherePlatformFailureDomainSpec holds the + region and zone failure domain and the vCenter topology + of that failure domain. properties: name: description: |- @@ -627,6 +627,65 @@ spec: maxLength: 80 minLength: 1 type: string + regionAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + enum: + - HostGroup + - ComputeCluster + - Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' server: anyOf: - format: ipv4 @@ -727,6 +786,65 @@ spec: maxLength: 80 minLength: 1 type: string + zoneAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + enum: + - HostGroup + - ComputeCluster + - Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field must + be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, type must + be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' required: - name - region @@ -734,6 +852,17 @@ spec: - topology - zone type: object + x-kubernetes-validations: + - message: when zoneAffinity type is HostGroup, regionAffinity + type must be ComputeCluster + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''HostGroup'' ? has(self.regionAffinity) && self.regionAffinity.type + == ''ComputeCluster'' : true' + - message: when zoneAffinity type is ComputeCluster, regionAffinity + type must be Datacenter + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''ComputeCluster'' ? has(self.regionAffinity) && + self.regionAffinity.type == ''Datacenter'' : true' type: array x-kubernetes-list-map-keys: - name diff --git a/payload-manifests/crds/0000_80_machine-config_01_controllerconfigs-CustomNoUpgrade.crd.yaml b/payload-manifests/crds/0000_80_machine-config_01_controllerconfigs-CustomNoUpgrade.crd.yaml index 42a59890bac..9eeff59509a 100644 --- a/payload-manifests/crds/0000_80_machine-config_01_controllerconfigs-CustomNoUpgrade.crd.yaml +++ b/payload-manifests/crds/0000_80_machine-config_01_controllerconfigs-CustomNoUpgrade.crd.yaml @@ -895,9 +895,9 @@ spec: failureDomains contains the definition of region, zone and the vCenter topology. If this is omitted failure domains (regions and zones) will not be used. items: - description: |- - VSpherePlatformFailureDomainSpec holds the region and zone failure domain and - the vCenter topology of that failure domain. + description: VSpherePlatformFailureDomainSpec holds + the region and zone failure domain and the vCenter + topology of that failure domain. properties: name: description: |- @@ -914,6 +914,65 @@ spec: maxLength: 80 minLength: 1 type: string + regionAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + enum: + - HostGroup + - ComputeCluster + - Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type + must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' server: description: server is the fully-qualified domain name or the IP address of the vCenter server. @@ -1010,6 +1069,65 @@ spec: maxLength: 80 minLength: 1 type: string + zoneAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + enum: + - HostGroup + - ComputeCluster + - Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type + must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' required: - name - region @@ -1017,6 +1135,19 @@ spec: - topology - zone type: object + x-kubernetes-validations: + - message: when zoneAffinity type is HostGroup, + regionAffinity type must be ComputeCluster + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''HostGroup'' ? has(self.regionAffinity) + && self.regionAffinity.type == ''ComputeCluster'' + : true' + - message: when zoneAffinity type is ComputeCluster, + regionAffinity type must be Datacenter + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''ComputeCluster'' ? has(self.regionAffinity) + && self.regionAffinity.type == ''Datacenter'' + : true' type: array x-kubernetes-list-map-keys: - name diff --git a/payload-manifests/crds/0000_80_machine-config_01_controllerconfigs-Default.crd.yaml b/payload-manifests/crds/0000_80_machine-config_01_controllerconfigs-Default.crd.yaml index d83951b43d8..d392552bc06 100644 --- a/payload-manifests/crds/0000_80_machine-config_01_controllerconfigs-Default.crd.yaml +++ b/payload-manifests/crds/0000_80_machine-config_01_controllerconfigs-Default.crd.yaml @@ -895,9 +895,9 @@ spec: failureDomains contains the definition of region, zone and the vCenter topology. If this is omitted failure domains (regions and zones) will not be used. items: - description: |- - VSpherePlatformFailureDomainSpec holds the region and zone failure domain and - the vCenter topology of that failure domain. + description: VSpherePlatformFailureDomainSpec holds + the region and zone failure domain and the vCenter + topology of that failure domain. properties: name: description: |- @@ -914,6 +914,61 @@ spec: maxLength: 80 minLength: 1 type: string + regionAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type + must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' server: description: server is the fully-qualified domain name or the IP address of the vCenter server. @@ -1010,6 +1065,61 @@ spec: maxLength: 80 minLength: 1 type: string + zoneAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type + must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' required: - name - region @@ -1017,6 +1127,19 @@ spec: - topology - zone type: object + x-kubernetes-validations: + - message: when zoneAffinity type is HostGroup, + regionAffinity type must be ComputeCluster + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''HostGroup'' ? has(self.regionAffinity) + && self.regionAffinity.type == ''ComputeCluster'' + : true' + - message: when zoneAffinity type is ComputeCluster, + regionAffinity type must be Datacenter + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''ComputeCluster'' ? has(self.regionAffinity) + && self.regionAffinity.type == ''Datacenter'' + : true' type: array x-kubernetes-list-map-keys: - name diff --git a/payload-manifests/crds/0000_80_machine-config_01_controllerconfigs-DevPreviewNoUpgrade.crd.yaml b/payload-manifests/crds/0000_80_machine-config_01_controllerconfigs-DevPreviewNoUpgrade.crd.yaml index ddd72e05e89..fd4da3c11fc 100644 --- a/payload-manifests/crds/0000_80_machine-config_01_controllerconfigs-DevPreviewNoUpgrade.crd.yaml +++ b/payload-manifests/crds/0000_80_machine-config_01_controllerconfigs-DevPreviewNoUpgrade.crd.yaml @@ -895,9 +895,9 @@ spec: failureDomains contains the definition of region, zone and the vCenter topology. If this is omitted failure domains (regions and zones) will not be used. items: - description: |- - VSpherePlatformFailureDomainSpec holds the region and zone failure domain and - the vCenter topology of that failure domain. + description: VSpherePlatformFailureDomainSpec holds + the region and zone failure domain and the vCenter + topology of that failure domain. properties: name: description: |- @@ -914,6 +914,65 @@ spec: maxLength: 80 minLength: 1 type: string + regionAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + enum: + - HostGroup + - ComputeCluster + - Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type + must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' server: description: server is the fully-qualified domain name or the IP address of the vCenter server. @@ -1010,6 +1069,65 @@ spec: maxLength: 80 minLength: 1 type: string + zoneAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + enum: + - HostGroup + - ComputeCluster + - Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type + must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' required: - name - region @@ -1017,6 +1135,19 @@ spec: - topology - zone type: object + x-kubernetes-validations: + - message: when zoneAffinity type is HostGroup, + regionAffinity type must be ComputeCluster + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''HostGroup'' ? has(self.regionAffinity) + && self.regionAffinity.type == ''ComputeCluster'' + : true' + - message: when zoneAffinity type is ComputeCluster, + regionAffinity type must be Datacenter + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''ComputeCluster'' ? has(self.regionAffinity) + && self.regionAffinity.type == ''Datacenter'' + : true' type: array x-kubernetes-list-map-keys: - name diff --git a/payload-manifests/crds/0000_80_machine-config_01_controllerconfigs-TechPreviewNoUpgrade.crd.yaml b/payload-manifests/crds/0000_80_machine-config_01_controllerconfigs-TechPreviewNoUpgrade.crd.yaml index 2e9b84d78d6..2da55b1da03 100644 --- a/payload-manifests/crds/0000_80_machine-config_01_controllerconfigs-TechPreviewNoUpgrade.crd.yaml +++ b/payload-manifests/crds/0000_80_machine-config_01_controllerconfigs-TechPreviewNoUpgrade.crd.yaml @@ -895,9 +895,9 @@ spec: failureDomains contains the definition of region, zone and the vCenter topology. If this is omitted failure domains (regions and zones) will not be used. items: - description: |- - VSpherePlatformFailureDomainSpec holds the region and zone failure domain and - the vCenter topology of that failure domain. + description: VSpherePlatformFailureDomainSpec holds + the region and zone failure domain and the vCenter + topology of that failure domain. properties: name: description: |- @@ -914,6 +914,65 @@ spec: maxLength: 80 minLength: 1 type: string + regionAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + enum: + - HostGroup + - ComputeCluster + - Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type + must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' server: description: server is the fully-qualified domain name or the IP address of the vCenter server. @@ -1010,6 +1069,65 @@ spec: maxLength: 80 minLength: 1 type: string + zoneAffinity: + description: |- + affinity holds the VMGroup and the HostGroup names in vCenter corresponds to + a vm-host group of type Virtual Machine and Host respectively. Is also + contains the VMHostRule which is an affinity vm-host rule in vCenter. + properties: + hostGroup: + description: |- + hostGroup is the name of the vm-host group of type host within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: + description: |- + The VSphereFailureDomainType is a string representation of a failure domain + type. There are three supportable types: HostGroup, ComputeCluster and Datacenter + enum: + - HostGroup + - ComputeCluster + - Datacenter + type: string + vmGroup: + description: |- + vmGroup is the name of the vm-host group of type virtual machine within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + vmHostRule: + description: |- + vmHostRule is the name of the affinity vm-host rule within vCenter for this failure domain. + This field is required when the VSphereFailureDomain ZoneType is HostGroup + maxLength: 80 + type: string + type: object + x-kubernetes-validations: + - message: when type is HostGroup, hostGroup + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.hostGroup) : true' + - message: when hostGroup field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.hostGroup) : true' + - message: when type is HostGroup, vmGroup field + must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmGroup) : true' + - message: when vmGroup field is defined, type + must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmGroup) : true' + - message: when type is HostGroup, vmHostRule + field must be defined + rule: 'has(self.type) && self.type == ''HostGroup'' + ? has(self.vmHostRule) : true' + - message: when vmHostRule field is defined, + type must be HostGroup + rule: 'has(self.type) && self.type != ''HostGroup'' + ? !has(self.vmHostRule) : true' required: - name - region @@ -1017,6 +1135,19 @@ spec: - topology - zone type: object + x-kubernetes-validations: + - message: when zoneAffinity type is HostGroup, + regionAffinity type must be ComputeCluster + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''HostGroup'' ? has(self.regionAffinity) + && self.regionAffinity.type == ''ComputeCluster'' + : true' + - message: when zoneAffinity type is ComputeCluster, + regionAffinity type must be Datacenter + rule: 'has(self.zoneAffinity) && self.zoneAffinity.type + == ''ComputeCluster'' ? has(self.regionAffinity) + && self.regionAffinity.type == ''Datacenter'' + : true' type: array x-kubernetes-list-map-keys: - name diff --git a/payload-manifests/featuregates/featureGate-Hypershift-Default.yaml b/payload-manifests/featuregates/featureGate-Hypershift-Default.yaml index d0ca8f129b7..29265b64795 100644 --- a/payload-manifests/featuregates/featureGate-Hypershift-Default.yaml +++ b/payload-manifests/featuregates/featureGate-Hypershift-Default.yaml @@ -151,6 +151,9 @@ { "name": "UserNamespacesSupport" }, + { + "name": "VSphereHostVMGroupZonal" + }, { "name": "VSphereMultiNetworks" }, diff --git a/payload-manifests/featuregates/featureGate-Hypershift-DevPreviewNoUpgrade.yaml b/payload-manifests/featuregates/featureGate-Hypershift-DevPreviewNoUpgrade.yaml index fc472569ae6..eee86a2cc8c 100644 --- a/payload-manifests/featuregates/featureGate-Hypershift-DevPreviewNoUpgrade.yaml +++ b/payload-manifests/featuregates/featureGate-Hypershift-DevPreviewNoUpgrade.yaml @@ -233,6 +233,9 @@ { "name": "VSphereDriverConfiguration" }, + { + "name": "VSphereHostVMGroupZonal" + }, { "name": "VSphereMultiNetworks" }, diff --git a/payload-manifests/featuregates/featureGate-Hypershift-TechPreviewNoUpgrade.yaml b/payload-manifests/featuregates/featureGate-Hypershift-TechPreviewNoUpgrade.yaml index 56bbf24a3a3..0acf2f46448 100644 --- a/payload-manifests/featuregates/featureGate-Hypershift-TechPreviewNoUpgrade.yaml +++ b/payload-manifests/featuregates/featureGate-Hypershift-TechPreviewNoUpgrade.yaml @@ -233,6 +233,9 @@ { "name": "VSphereDriverConfiguration" }, + { + "name": "VSphereHostVMGroupZonal" + }, { "name": "VSphereMultiNetworks" }, diff --git a/payload-manifests/featuregates/featureGate-SelfManagedHA-Default.yaml b/payload-manifests/featuregates/featureGate-SelfManagedHA-Default.yaml index 42ce1fd09bb..1d720ae4bfe 100644 --- a/payload-manifests/featuregates/featureGate-SelfManagedHA-Default.yaml +++ b/payload-manifests/featuregates/featureGate-SelfManagedHA-Default.yaml @@ -154,6 +154,9 @@ { "name": "UserNamespacesSupport" }, + { + "name": "VSphereHostVMGroupZonal" + }, { "name": "VSphereMultiNetworks" }, diff --git a/payload-manifests/featuregates/featureGate-SelfManagedHA-DevPreviewNoUpgrade.yaml b/payload-manifests/featuregates/featureGate-SelfManagedHA-DevPreviewNoUpgrade.yaml index 233d63bbfea..2befab4d2f1 100644 --- a/payload-manifests/featuregates/featureGate-SelfManagedHA-DevPreviewNoUpgrade.yaml +++ b/payload-manifests/featuregates/featureGate-SelfManagedHA-DevPreviewNoUpgrade.yaml @@ -233,6 +233,9 @@ { "name": "VSphereDriverConfiguration" }, + { + "name": "VSphereHostVMGroupZonal" + }, { "name": "VSphereMultiNetworks" }, diff --git a/payload-manifests/featuregates/featureGate-SelfManagedHA-TechPreviewNoUpgrade.yaml b/payload-manifests/featuregates/featureGate-SelfManagedHA-TechPreviewNoUpgrade.yaml index 8cfa5d89fe7..74739a62a88 100644 --- a/payload-manifests/featuregates/featureGate-SelfManagedHA-TechPreviewNoUpgrade.yaml +++ b/payload-manifests/featuregates/featureGate-SelfManagedHA-TechPreviewNoUpgrade.yaml @@ -233,6 +233,9 @@ { "name": "VSphereDriverConfiguration" }, + { + "name": "VSphereHostVMGroupZonal" + }, { "name": "VSphereMultiNetworks" }, diff --git a/tests/generator.go b/tests/generator.go index 9ec1c59c946..2513ee47d19 100644 --- a/tests/generator.go +++ b/tests/generator.go @@ -160,6 +160,11 @@ func generateOnCreateTable(onCreateTests []OnCreateTestSpec) { Expect(err).ToNot(HaveOccurred(), "initial data should be a valid Kubernetes YAML resource") err = k8sClient.Create(ctx, initialObj) + + if err != nil { + fmt.Printf("ERROR MSG: %s", err.Error()) + } + if in.expectedError != "" { Expect(err).To(MatchError(ContainSubstring(in.expectedError))) return @@ -246,6 +251,9 @@ func generateOnUpdateTable(onUpdateTests []OnUpdateTestSpec) { updatedObj.SetResourceVersion(gotObj.GetResourceVersion()) err = k8sClient.Update(ctx, updatedObj) + if err != nil { + fmt.Printf("ERROR MSG: %s", err.Error()) + } if in.expectedError != "" { Expect(err).To(MatchError(ContainSubstring(in.expectedError))) return diff --git a/tests/suite_test.go b/tests/suite_test.go index 321b8ace436..50a38b4203e 100644 --- a/tests/suite_test.go +++ b/tests/suite_test.go @@ -10,6 +10,7 @@ import ( . "github.com/onsi/ginkgo/v2" . "github.com/onsi/gomega" + "github.com/onsi/gomega/format" "k8s.io/apimachinery/pkg/runtime" "k8s.io/client-go/discovery" @@ -34,10 +35,11 @@ func TestAPIs(t *testing.T) { RegisterFailHandler(Fail) g := NewGomegaWithT(t) + format.MaxLength = 0 var err error // this assumes a directory. Because it does, we shall assume a path to the serialized featuregate manifests too. - suites, err = LoadTestSuiteSpecs(filepath.Join("..")) + suites, err = LoadTestSuiteSpecs(filepath.Join("../config/v1/tests/infrastructures.config.openshift.io")) g.Expect(err).ToNot(HaveOccurred()) RunSpecs(t, "API Integration Suite")