11# Creates a cluster with one control-plane node and one worker node
2- apiVersion : infrastructure.cluster.x-k8s.io/v1alpha3
2+ apiVersion : infrastructure.cluster.x-k8s.io/v1alpha4
33kind : MaasCluster
44metadata :
55 name : my-cluster
66spec :
77 dnsDomain : maas.sc
88
99---
10- apiVersion : cluster.x-k8s.io/v1alpha3
10+ apiVersion : cluster.x-k8s.io/v1alpha4
1111kind : Cluster
1212metadata :
1313 name : my-cluster
@@ -19,17 +19,17 @@ spec:
1919 cidrBlocks : ["192.168.0.0/16"]
2020 serviceDomain : " cluster.local"
2121 controlPlaneRef :
22- apiVersion : controlplane.cluster.x-k8s.io/v1alpha3
22+ apiVersion : controlplane.cluster.x-k8s.io/v1alpha4
2323 kind : KubeadmControlPlane
2424 name : my-cluster-cp
2525 namespace : default
2626 infrastructureRef :
27- apiVersion : infrastructure.cluster.x-k8s.io/v1alpha3
27+ apiVersion : infrastructure.cluster.x-k8s.io/v1alpha4
2828 kind : MaasCluster
2929 name : my-cluster
3030 namespace : default
3131---
32- apiVersion : infrastructure.cluster.x-k8s.io/v1alpha3
32+ apiVersion : infrastructure.cluster.x-k8s.io/v1alpha4
3333kind : MaasMachineTemplate
3434metadata :
3535 name : my-cluster-cp
@@ -41,19 +41,20 @@ spec:
4141 minMemory : 8192
4242 image : u-1804-0-k-11912-0
4343---
44- apiVersion : controlplane.cluster.x-k8s.io/v1alpha3
44+ apiVersion : controlplane.cluster.x-k8s.io/v1alpha4
4545kind : KubeadmControlPlane
4646metadata :
4747 name : my-cluster-cp
4848 namespace : default
4949spec :
5050 replicas : 1
5151 version : v1.19.12
52- infrastructureTemplate :
53- apiVersion : infrastructure.cluster.x-k8s.io/v1alpha3
54- kind : MaasMachineTemplate
55- name : my-cluster-cp
56- namespace : default
52+ machineTemplate :
53+ infrastructureRef :
54+ apiVersion : infrastructure.cluster.x-k8s.io/v1alpha4
55+ kind : MaasMachineTemplate
56+ name : my-cluster-cp
57+ namespace : default
5758 kubeadmConfigSpec :
5859 clusterConfiguration :
5960 apiServer :
@@ -107,7 +108,7 @@ spec:
107108 useExperimentalRetryJoin : true
108109---
109110status :
110- apiVersion : infrastructure.cluster.x-k8s.io/v1alpha3
111+ apiVersion : infrastructure.cluster.x-k8s.io/v1alpha4
111112kind : MaasMachineTemplate
112113metadata :
113114 name : my-cluster-worker
@@ -119,7 +120,7 @@ spec:
119120 minMemory : 8192
120121 image : u-1804-0-k-11912-0
121122---
122- apiVersion : cluster.x-k8s.io/v1alpha3
123+ apiVersion : cluster.x-k8s.io/v1alpha4
123124kind : MachineDeployment
124125metadata :
125126 name : my-cluster-worker
@@ -136,15 +137,15 @@ spec:
136137 version : 1.19.12
137138 bootstrap :
138139 configRef :
139- apiVersion : bootstrap.cluster.x-k8s.io/v1alpha3
140+ apiVersion : bootstrap.cluster.x-k8s.io/v1alpha4
140141 kind : KubeadmConfigTemplate
141142 name : my-cluster-worker
142143 infrastructureRef :
143- apiVersion : infrastructure.cluster.x-k8s.io/v1alpha3
144+ apiVersion : infrastructure.cluster.x-k8s.io/v1alpha4
144145 kind : MaasMachineTemplate
145146 name : my-cluster-worker
146147---
147- apiVersion : bootstrap.cluster.x-k8s.io/v1alpha3
148+ apiVersion : bootstrap.cluster.x-k8s.io/v1alpha4
148149kind : KubeadmConfigTemplate
149150metadata :
150151 name : my-cluster-worker
0 commit comments