fix: Change CIDR subnet block #2
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
Danny Bessems 2023-08-24 15:28:09 +02:00
parent ef58b823c2
commit bb58e287b7
2 changed files with 10 additions and 3 deletions

View File

@ -305,7 +305,12 @@
# TODO: move to git repo # TODO: move to git repo
- name: Apply cni plugin manifest - name: Apply cni plugin manifest
kubernetes.core.k8s: kubernetes.core.k8s:
src: /opt/metacluster/cluster-api/cni-calico/{{ components.clusterapi.workload.version.calico }}/calico.yaml definition: |
{{
lookup('ansible.builtin.file', '/opt/metacluster/cluster-api/cni-calico/' ~ components.clusterapi.workload.version.calico ~ '/calico.yaml') |
regex_replace('# - name: CALICO_IPV4POOL_CIDR', '- name: CALICO_IPV4POOL_CIDR') |
regex_replace('# value: "192.168.0.0/16"', ' value: "172.30.0.0/16"')
}}
state: present state: present
wait: true wait: true
kubeconfig: "{{ capi_kubeconfig.path }}" kubeconfig: "{{ capi_kubeconfig.path }}"

View File

@ -217,8 +217,10 @@ patches:
name: \${CLUSTER_NAME} name: \${CLUSTER_NAME}
patch: |- patch: |-
- op: replace - op: replace
path: /spec/clusterNetwork/pods/cidrBlocks/- path: /spec/clusterNetwork/pods
value: 172.30.0.0/16 value:
cidrBlocks:
- 172.30.0.0/16
- op: replace - op: replace
path: /spec/controlPlaneRef/name path: /spec/controlPlaneRef/name
value: ${CLUSTER_NAME}-master value: ${CLUSTER_NAME}-master