|
| 1 | +apiVersion: v1 |
| 2 | +data: |
| 3 | + cacert: ${OPENSTACK_CLOUD_CACERT_B64} |
| 4 | + clouds.yaml: ${OPENSTACK_CLOUD_YAML_B64} |
| 5 | +kind: Secret |
| 6 | +metadata: |
| 7 | + labels: |
| 8 | + clusterctl.cluster.x-k8s.io/move: "true" |
| 9 | + name: ${CLUSTER_NAME}-cloud-config |
| 10 | +--- |
| 11 | +apiVersion: bootstrap.cluster.x-k8s.io/v1beta1 |
| 12 | +kind: KubeadmConfigTemplate |
| 13 | +metadata: |
| 14 | + name: ${CLUSTER_NAME}-md-0 |
| 15 | +spec: |
| 16 | + template: |
| 17 | + spec: |
| 18 | + files: |
| 19 | + - content: ${OPENSTACK_CLOUD_PROVIDER_CONF_B64} |
| 20 | + encoding: base64 |
| 21 | + owner: root |
| 22 | + path: /etc/kubernetes/cloud.conf |
| 23 | + permissions: "0600" |
| 24 | + - content: ${OPENSTACK_CLOUD_CACERT_B64} |
| 25 | + encoding: base64 |
| 26 | + owner: root |
| 27 | + path: /etc/certs/cacert |
| 28 | + permissions: "0600" |
| 29 | + joinConfiguration: |
| 30 | + nodeRegistration: |
| 31 | + kubeletExtraArgs: |
| 32 | + cloud-config: /etc/kubernetes/cloud.conf |
| 33 | + cloud-provider: openstack |
| 34 | + name: '{{ local_hostname }}' |
| 35 | +--- |
| 36 | +apiVersion: cluster.x-k8s.io/v1beta1 |
| 37 | +kind: Cluster |
| 38 | +metadata: |
| 39 | + name: ${CLUSTER_NAME} |
| 40 | +spec: |
| 41 | + clusterNetwork: |
| 42 | + pods: |
| 43 | + cidrBlocks: |
| 44 | + - 192.168.0.0/16 |
| 45 | + serviceDomain: cluster.local |
| 46 | + controlPlaneRef: |
| 47 | + apiVersion: controlplane.cluster.x-k8s.io/v1beta1 |
| 48 | + kind: KubeadmControlPlane |
| 49 | + name: ${CLUSTER_NAME}-control-plane |
| 50 | + infrastructureRef: |
| 51 | + apiVersion: infrastructure.cluster.x-k8s.io/v1alpha6 |
| 52 | + kind: OpenStackCluster |
| 53 | + name: ${CLUSTER_NAME} |
| 54 | +--- |
| 55 | +apiVersion: cluster.x-k8s.io/v1beta1 |
| 56 | +kind: MachineDeployment |
| 57 | +metadata: |
| 58 | + name: ${CLUSTER_NAME}-md-0 |
| 59 | +spec: |
| 60 | + clusterName: ${CLUSTER_NAME} |
| 61 | + replicas: ${WORKER_MACHINE_COUNT} |
| 62 | + selector: |
| 63 | + matchLabels: null |
| 64 | + template: |
| 65 | + spec: |
| 66 | + bootstrap: |
| 67 | + configRef: |
| 68 | + apiVersion: bootstrap.cluster.x-k8s.io/v1beta1 |
| 69 | + kind: KubeadmConfigTemplate |
| 70 | + name: ${CLUSTER_NAME}-md-0 |
| 71 | + clusterName: ${CLUSTER_NAME} |
| 72 | + failureDomain: ${OPENSTACK_FAILURE_DOMAIN} |
| 73 | + infrastructureRef: |
| 74 | + apiVersion: infrastructure.cluster.x-k8s.io/v1alpha6 |
| 75 | + kind: OpenStackMachineTemplate |
| 76 | + name: ${CLUSTER_NAME}-md-0 |
| 77 | + version: ${KUBERNETES_VERSION} |
| 78 | +--- |
| 79 | +apiVersion: controlplane.cluster.x-k8s.io/v1beta1 |
| 80 | +kind: KubeadmControlPlane |
| 81 | +metadata: |
| 82 | + name: ${CLUSTER_NAME}-control-plane |
| 83 | +spec: |
| 84 | + kubeadmConfigSpec: |
| 85 | + clusterConfiguration: |
| 86 | + apiServer: |
| 87 | + extraArgs: |
| 88 | + cloud-config: /etc/kubernetes/cloud.conf |
| 89 | + cloud-provider: openstack |
| 90 | + extraVolumes: |
| 91 | + - hostPath: /etc/kubernetes/cloud.conf |
| 92 | + mountPath: /etc/kubernetes/cloud.conf |
| 93 | + name: cloud |
| 94 | + readOnly: true |
| 95 | + controllerManager: |
| 96 | + extraArgs: |
| 97 | + cloud-config: /etc/kubernetes/cloud.conf |
| 98 | + cloud-provider: openstack |
| 99 | + extraVolumes: |
| 100 | + - hostPath: /etc/kubernetes/cloud.conf |
| 101 | + mountPath: /etc/kubernetes/cloud.conf |
| 102 | + name: cloud |
| 103 | + readOnly: true |
| 104 | + - hostPath: /etc/certs/cacert |
| 105 | + mountPath: /etc/certs/cacert |
| 106 | + name: cacerts |
| 107 | + readOnly: true |
| 108 | + files: |
| 109 | + - content: ${OPENSTACK_CLOUD_PROVIDER_CONF_B64} |
| 110 | + encoding: base64 |
| 111 | + owner: root |
| 112 | + path: /etc/kubernetes/cloud.conf |
| 113 | + permissions: "0600" |
| 114 | + - content: ${OPENSTACK_CLOUD_CACERT_B64} |
| 115 | + encoding: base64 |
| 116 | + owner: root |
| 117 | + path: /etc/certs/cacert |
| 118 | + permissions: "0600" |
| 119 | + initConfiguration: |
| 120 | + nodeRegistration: |
| 121 | + kubeletExtraArgs: |
| 122 | + cloud-config: /etc/kubernetes/cloud.conf |
| 123 | + cloud-provider: openstack |
| 124 | + name: '{{ local_hostname }}' |
| 125 | + joinConfiguration: |
| 126 | + nodeRegistration: |
| 127 | + kubeletExtraArgs: |
| 128 | + cloud-config: /etc/kubernetes/cloud.conf |
| 129 | + cloud-provider: openstack |
| 130 | + name: '{{ local_hostname }}' |
| 131 | + machineTemplate: |
| 132 | + infrastructureRef: |
| 133 | + apiVersion: infrastructure.cluster.x-k8s.io/v1alpha6 |
| 134 | + kind: OpenStackMachineTemplate |
| 135 | + name: ${CLUSTER_NAME}-control-plane |
| 136 | + replicas: 1 |
| 137 | + version: ${KUBERNETES_VERSION} |
| 138 | +--- |
| 139 | +apiVersion: infrastructure.cluster.x-k8s.io/v1alpha6 |
| 140 | +kind: OpenStackCluster |
| 141 | +metadata: |
| 142 | + name: ${CLUSTER_NAME} |
| 143 | +spec: |
| 144 | + cloudName: ${OPENSTACK_CLOUD} |
| 145 | + dnsNameservers: |
| 146 | + - ${OPENSTACK_DNS_NAMESERVERS} |
| 147 | + externalNetworkId: ${OPENSTACK_EXTERNAL_NETWORK_ID} |
| 148 | + identityRef: |
| 149 | + kind: Secret |
| 150 | + name: ${CLUSTER_NAME}-cloud-config |
| 151 | + managedSecurityGroups: true |
| 152 | + nodeCidr: 10.6.0.0/24 |
| 153 | +--- |
| 154 | +apiVersion: infrastructure.cluster.x-k8s.io/v1alpha6 |
| 155 | +kind: OpenStackMachineTemplate |
| 156 | +metadata: |
| 157 | + name: ${CLUSTER_NAME}-control-plane |
| 158 | +spec: |
| 159 | + template: |
| 160 | + spec: |
| 161 | + cloudName: ${OPENSTACK_CLOUD} |
| 162 | + flavor: ${OPENSTACK_CONTROL_PLANE_MACHINE_FLAVOR} |
| 163 | + identityRef: |
| 164 | + kind: Secret |
| 165 | + name: ${CLUSTER_NAME}-cloud-config |
| 166 | + image: ${OPENSTACK_IMAGE_NAME} |
| 167 | + sshKeyName: ${OPENSTACK_SSH_KEY_NAME} |
| 168 | +--- |
| 169 | +apiVersion: infrastructure.cluster.x-k8s.io/v1alpha6 |
| 170 | +kind: OpenStackMachineTemplate |
| 171 | +metadata: |
| 172 | + name: ${CLUSTER_NAME}-md-0 |
| 173 | +spec: |
| 174 | + template: |
| 175 | + spec: |
| 176 | + cloudName: ${OPENSTACK_CLOUD} |
| 177 | + flavor: ${OPENSTACK_NODE_MACHINE_FLAVOR} |
| 178 | + identityRef: |
| 179 | + kind: Secret |
| 180 | + name: ${CLUSTER_NAME}-cloud-config |
| 181 | + image: ${OPENSTACK_IMAGE_NAME} |
| 182 | + sshKeyName: ${OPENSTACK_SSH_KEY_NAME} |
0 commit comments