Skip to content

Commit 45d190f

Browse files
authored
Merge pull request #5994 from sbueringer/pr-cc-prop-fix-yaml
📖 ClusterClass: fix YAMLs in proposal
2 parents 992a83c + 1ab0483 commit 45d190f

File tree

1 file changed

+20
-15
lines changed

1 file changed

+20
-15
lines changed

docs/proposals/202105256-cluster-class-and-managed-topologies.md

Lines changed: 20 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -770,17 +770,22 @@ intentionally use resources without patches and variables to focus on the simple
770770
##### Create a new Cluster using ClusterClass object
771771
1. User creates a ClusterClass object.
772772
```yaml
773-
apiVersion: cluster.x-k8s.io/v1alpha4
773+
apiVersion: cluster.x-k8s.io/v1beta1
774774
kind: ClusterClass
775775
metadata:
776776
name: mixed
777777
namespace: bar
778778
spec:
779779
controlPlane:
780780
ref:
781-
apiVersion: controlplane.cluster.x-k8s.io/v1alpha4
781+
apiVersion: controlplane.cluster.x-k8s.io/v1beta1
782782
kind: KubeadmControlPlaneTemplate
783783
name: vsphere-prod-cluster-template-kcp
784+
machineInfrastructure:
785+
ref:
786+
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1
787+
kind: VSphereMachineTemplate
788+
name: linux-vsphere-template
784789
# This will create a MachineHealthCheck for ControlPlane machines.
785790
machineHealthCheck:
786791
nodeStartupTimeout: 3m
@@ -793,17 +798,17 @@ intentionally use resources without patches and variables to focus on the simple
793798
status: "False"
794799
timeout: 300s
795800
workers:
796-
deployments:
801+
machineDeployments:
797802
- class: linux-worker
798803
template:
799804
bootstrap:
800805
ref:
801-
apiVersion: bootstrap.cluster.x-k8s.io/v1alpha4
806+
apiVersion: bootstrap.cluster.x-k8s.io/v1beta1
802807
kind: KubeadmConfigTemplate
803808
name: existing-boot-ref
804809
infrastructure:
805810
ref:
806-
apiVersion: infrastructure.cluster.x-k8s.io/v1alpha4
811+
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1
807812
kind: VSphereMachineTemplate
808813
name: linux-vsphere-template
809814
# This will create a health check for each deployment created with the "linux-worker" MachineDeploymentClass
@@ -814,17 +819,17 @@ intentionally use resources without patches and variables to focus on the simple
814819
timeout: 300s
815820
- type: Ready
816821
status: "False"
817-
timeout: 300s
822+
timeout: 300s
818823
- class: windows-worker
819824
template:
820825
bootstrap:
821826
ref:
822-
apiVersion: bootstrap.cluster.x-k8s.io/v1alpha4
827+
apiVersion: bootstrap.cluster.x-k8s.io/v1beta1
823828
kind: KubeadmConfigTemplate
824829
name: existing-boot-ref-windows
825830
infrastructure:
826831
ref:
827-
apiVersion: infrastructure.cluster.x-k8s.io/v1alpha4
832+
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1
828833
kind: VSphereMachineTemplate
829834
name: windows-vsphere-template
830835
# This will create a health check for each deployment created with the "windows-worker" MachineDeploymentClass
@@ -835,16 +840,16 @@ intentionally use resources without patches and variables to focus on the simple
835840
timeout: 300s
836841
- type: Ready
837842
status: "False"
838-
timeout: 300s
843+
timeout: 300s
839844
infrastructure:
840845
ref:
841-
apiVersion: infrastructure.cluster.x-k8s.io/v1alpha4
846+
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1
842847
kind: VSphereClusterTemplate
843848
name: vsphere-prod-cluster-template
844849
```
845850
2. User creates a cluster using the class name and defining the topology.
846851
```yaml
847-
apiVersion: cluster.x-k8s.io/v1alpha4
852+
apiVersion: cluster.x-k8s.io/v1beta1
848853
kind: Cluster
849854
metadata:
850855
name: foo
@@ -941,7 +946,7 @@ to avoid creating separate ClusterClasses for every small deviation, e.g. a diff
941946

942947
1. User creates a ClusterClass object with variables and patches (other fields are omitted for brevity).
943948
```yaml
944-
apiVersion: cluster.x-k8s.io/v1alpha4
949+
apiVersion: cluster.x-k8s.io/v1beta1
945950
kind: ClusterClass
946951
metadata:
947952
name: my-cluster-class
@@ -962,7 +967,7 @@ to avoid creating separate ClusterClasses for every small deviation, e.g. a diff
962967
- name: region
963968
definitions:
964969
- selector:
965-
apiVersion: infrastructure.cluster.x-k8s.io/v1alpha4
970+
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1
966971
kind: AWSClusterTemplate
967972
jsonPatches:
968973
- op: replace
@@ -972,7 +977,7 @@ to avoid creating separate ClusterClasses for every small deviation, e.g. a diff
972977
- name: controlPlaneMachineType
973978
definitions:
974979
- selector:
975-
apiVersion: infrastructure.cluster.x-k8s.io/v1alpha4
980+
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1
976981
kind: AWSMachineTemplate
977982
matchResources:
978983
controlPlane: true
@@ -987,7 +992,7 @@ to avoid creating separate ClusterClasses for every small deviation, e.g. a diff
987992

988993
1. User creates a Cluster referencing the ClusterClass created above and defining variables (other fields are omitted for brevity).
989994
```yaml
990-
apiVersion: cluster.x-k8s.io/v1alpha4
995+
apiVersion: cluster.x-k8s.io/v1beta1
991996
kind: Cluster
992997
metadata:
993998
name: my-cluster

0 commit comments

Comments
 (0)