2023-04-06 11:29:29 +00:00
|
|
|
apiVersion: kustomize.config.k8s.io/v1beta1
|
|
|
|
kind: Kustomization
|
|
|
|
resources:
|
|
|
|
- manifests/kubeadmconfigtemplate-{{ _template.cluster.name }}-worker.yaml
|
|
|
|
- manifests/machinedeployment-{{ _template.cluster.name }}-worker.yaml
|
|
|
|
- manifests/vspheremachinetemplate-{{ _template.cluster.name }}-worker.yaml
|
|
|
|
|
|
|
|
patchesStrategicMerge:
|
|
|
|
- |-
|
|
|
|
apiVersion: bootstrap.cluster.x-k8s.io/v1beta1
|
|
|
|
kind: KubeadmConfigTemplate
|
|
|
|
metadata:
|
|
|
|
name: {{ _template.cluster.name }}-worker
|
|
|
|
namespace: default
|
|
|
|
spec:
|
|
|
|
template:
|
|
|
|
spec:
|
|
|
|
diskSetup:
|
|
|
|
filesystems:
|
|
|
|
- device: /dev/sdb1
|
|
|
|
filesystem: ext4
|
|
|
|
label: blockstorage
|
|
|
|
partitions:
|
|
|
|
- device: /dev/sdb
|
|
|
|
layout: true
|
|
|
|
tableType: gpt
|
|
|
|
mounts:
|
|
|
|
- - LABEL=blockstorage
|
|
|
|
- /mnt/blockstorage
|
2023-04-07 08:29:41 +00:00
|
|
|
- |-
|
|
|
|
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1
|
|
|
|
kind: VSphereMachineTemplate
|
|
|
|
metadata:
|
|
|
|
name: {{ _template.cluster.name }}-worker
|
|
|
|
namespace: default
|
|
|
|
spec:
|
|
|
|
template:
|
|
|
|
spec:
|
|
|
|
additionalDisksGiB:
|
|
|
|
- {{ _template.nodepool.additionaldisk }}
|
2023-04-06 11:29:29 +00:00
|
|
|
|
|
|
|
patchesJson6902:
|
|
|
|
- target:
|
|
|
|
group: bootstrap.cluster.x-k8s.io
|
|
|
|
version: v1beta1
|
|
|
|
kind: KubeadmConfigTemplate
|
|
|
|
name: {{ _template.cluster.name }}-worker
|
|
|
|
patch: |-
|
|
|
|
- op: replace
|
|
|
|
path: /metadata/name
|
|
|
|
value: {{ _template.cluster.name }}-worker-storage
|
|
|
|
|
|
|
|
- target:
|
|
|
|
group: cluster.x-k8s.io
|
|
|
|
version: v1beta1
|
|
|
|
kind: MachineDeployment
|
|
|
|
name: {{ _template.cluster.name }}-worker
|
|
|
|
patch: |-
|
|
|
|
- op: replace
|
|
|
|
path: /metadata/name
|
|
|
|
value: {{ _template.cluster.name }}-worker-storage
|
|
|
|
- op: replace
|
|
|
|
path: /spec/template/spec/bootstrap/configRef/name
|
|
|
|
value: {{ _template.cluster.name }}-worker-storage
|
|
|
|
- op: replace
|
|
|
|
path: /spec/template/spec/infrastructureRef/name
|
|
|
|
value: {{ _template.cluster.name }}-worker-storage
|
|
|
|
- op: replace
|
|
|
|
path: /spec/replicas
|
|
|
|
value: {{ _template.nodepool.size }}
|
|
|
|
|
|
|
|
- target:
|
|
|
|
group: infrastructure.cluster.x-k8s.io
|
|
|
|
version: v1beta1
|
|
|
|
kind: VSphereMachineTemplate
|
|
|
|
name: {{ _template.cluster.name }}-worker
|
|
|
|
patch: |-
|
|
|
|
- op: replace
|
|
|
|
path: /metadata/name
|
|
|
|
value: {{ _template.cluster.name }}-worker-storage
|