|
| 1 | +apiVersion: cluster.x-k8s.io/v1beta1 |
| 2 | +kind: Cluster |
| 3 | +metadata: |
| 4 | + name: "${CLUSTER_NAME}" |
| 5 | + namespace: "${NAMESPACE}" |
| 6 | +spec: |
| 7 | + clusterNetwork: |
| 8 | + pods: |
| 9 | + cidrBlocks: |
| 10 | + - 10.243.0.0/16 |
| 11 | + services: |
| 12 | + cidrBlocks: |
| 13 | + - 10.95.0.0/16 |
| 14 | + controlPlaneRef: |
| 15 | + apiVersion: controlplane.cluster.x-k8s.io/v1alpha1 |
| 16 | + kind: KamajiControlPlane |
| 17 | + name: '${CLUSTER_NAME}-control-plane' |
| 18 | + namespace: "${NAMESPACE}" |
| 19 | + infrastructureRef: |
| 20 | + apiVersion: infrastructure.cluster.x-k8s.io/v1alpha1 |
| 21 | + kind: KubevirtCluster |
| 22 | + name: '${CLUSTER_NAME}' |
| 23 | + namespace: "${NAMESPACE}" |
| 24 | +--- |
| 25 | +apiVersion: infrastructure.cluster.x-k8s.io/v1alpha1 |
| 26 | +kind: KubevirtCluster |
| 27 | +metadata: |
| 28 | + annotations: |
| 29 | + cluster.x-k8s.io/managed-by: kamaji |
| 30 | + name: "${CLUSTER_NAME}" |
| 31 | + namespace: "${NAMESPACE}" |
| 32 | +spec: {} |
| 33 | +--- |
| 34 | +apiVersion: controlplane.cluster.x-k8s.io/v1alpha1 |
| 35 | +kind: KamajiControlPlane |
| 36 | +metadata: |
| 37 | + name: '${CLUSTER_NAME}-control-plane' |
| 38 | + namespace: "${NAMESPACE}" |
| 39 | +spec: |
| 40 | + dataStoreName: default |
| 41 | + addons: |
| 42 | + coreDNS: |
| 43 | + dnsServiceIPs: |
| 44 | + - 10.95.0.10 |
| 45 | + kubeProxy: {} |
| 46 | + konnectivity: {} |
| 47 | + kubelet: |
| 48 | + cgroupfs: systemd |
| 49 | + preferredAddressTypes: |
| 50 | + - InternalIP |
| 51 | + - ExternalIP |
| 52 | + network: |
| 53 | + serviceType: LoadBalancer |
| 54 | + serviceAnnotations: |
| 55 | + kube-vip.io/loadbalancerIPs: 0.0.0.0 |
| 56 | + deployment: |
| 57 | + replicas: ${CONTROL_PLANE_MACHINE_COUNT} |
| 58 | + version: "${KUBERNETES_VERSION}" |
| 59 | +--- |
| 60 | +apiVersion: infrastructure.cluster.x-k8s.io/v1alpha1 |
| 61 | +kind: KubevirtMachineTemplate |
| 62 | +metadata: |
| 63 | + name: "${CLUSTER_NAME}-md-0" |
| 64 | + namespace: "${NAMESPACE}" |
| 65 | +spec: |
| 66 | + template: |
| 67 | + spec: |
| 68 | + virtualMachineBootstrapCheck: |
| 69 | + checkStrategy: none |
| 70 | + virtualMachineTemplate: |
| 71 | + spec: |
| 72 | + dataVolumeTemplates: |
| 73 | + - metadata: |
| 74 | + name: "${CLUSTER_NAME}-boot-volume" |
| 75 | + spec: |
| 76 | + pvc: |
| 77 | + accessModes: |
| 78 | + - ReadWriteOnce |
| 79 | + resources: |
| 80 | + requests: |
| 81 | + storage: 20Gi |
| 82 | + storageClassName: hvl |
| 83 | + source: |
| 84 | + registry: |
| 85 | + url: "docker://${NODE_VM_IMAGE_TEMPLATE}" |
| 86 | + runStrategy: Always |
| 87 | + template: |
| 88 | + spec: |
| 89 | + domain: |
| 90 | + cpu: |
| 91 | + cores: ${WORKER_MACHINE_CPU} |
| 92 | + sockets: ${SOCKETS} |
| 93 | + threads: ${THREADS} |
| 94 | + devices: |
| 95 | + interfaces: |
| 96 | + - bridge: {} |
| 97 | + model: virtio |
| 98 | + name: default |
| 99 | + - bridge: {} |
| 100 | + model: virtio |
| 101 | + name: secondary |
| 102 | + disks: |
| 103 | + - disk: |
| 104 | + bus: virtio |
| 105 | + name: dv-volume |
| 106 | + resources: |
| 107 | + limits: |
| 108 | + cpu: ${WORKER_MACHINE_CPU} |
| 109 | + memory: "${WORKER_MACHINE_MEMORY}Gi" |
| 110 | + requests: |
| 111 | + cpu: ${WORKER_MACHINE_CPU} |
| 112 | + memory: "${WORKER_MACHINE_MEMORY}Gi" |
| 113 | + evictionStrategy: External |
| 114 | + networks: |
| 115 | + - name: default |
| 116 | + pod: {} |
| 117 | + - multus: |
| 118 | + networkName: default/vmnet |
| 119 | + name: secondary |
| 120 | + volumes: |
| 121 | + - dataVolume: |
| 122 | + name: "${CLUSTER_NAME}-boot-volume" |
| 123 | + name: dv-volume |
| 124 | +--- |
| 125 | +apiVersion: bootstrap.cluster.x-k8s.io/v1beta1 |
| 126 | +kind: KubeadmConfigTemplate |
| 127 | +metadata: |
| 128 | + name: "${CLUSTER_NAME}-md-0" |
| 129 | + namespace: "${NAMESPACE}" |
| 130 | +spec: |
| 131 | + template: |
| 132 | + spec: |
| 133 | + joinConfiguration: |
| 134 | + nodeRegistration: |
| 135 | + kubeletExtraArgs: {} |
| 136 | +--- |
| 137 | +apiVersion: cluster.x-k8s.io/v1beta1 |
| 138 | +kind: MachineDeployment |
| 139 | +metadata: |
| 140 | + name: "${CLUSTER_NAME}-md-0" |
| 141 | + namespace: "${NAMESPACE}" |
| 142 | +spec: |
| 143 | + clusterName: "${CLUSTER_NAME}" |
| 144 | + replicas: ${WORKER_MACHINE_COUNT} |
| 145 | + selector: |
| 146 | + matchLabels: null |
| 147 | + template: |
| 148 | + spec: |
| 149 | + clusterName: "${CLUSTER_NAME}" |
| 150 | + version: "${KUBERNETES_VERSION}" |
| 151 | + bootstrap: |
| 152 | + configRef: |
| 153 | + apiVersion: bootstrap.cluster.x-k8s.io/v1beta1 |
| 154 | + kind: KubeadmConfigTemplate |
| 155 | + name: "${CLUSTER_NAME}-md-0" |
| 156 | + namespace: "${NAMESPACE}" |
| 157 | + infrastructureRef: |
| 158 | + apiVersion: infrastructure.cluster.x-k8s.io/v1alpha1 |
| 159 | + kind: KubevirtMachineTemplate |
| 160 | + name: "${CLUSTER_NAME}-md-0" |
| 161 | + namespace: "${NAMESPACE}" |
0 commit comments