This commit is contained in:
Michael McCulloch 2024-01-01 16:58:22 -07:00
parent 74aa4a8a4e
commit e09e979d27

View File

@ -45,12 +45,6 @@
state: link state: link
mode: 0644 mode: 0644
- name: Taint nodes with cilium agent-not-ready
command: kubectl taint nodes --all node.cilium.io/agent-not-ready=true:NoExecute
when:
- kubernetes_pod_network.cni == 'cilium'
- not kubernetes_init_stat.stat.exists
- name: Check if Cilium CLI has already been Installed. - name: Check if Cilium CLI has already been Installed.
stat: stat:
path: /usr/local/bin/cilium path: /usr/local/bin/cilium
@ -100,12 +94,27 @@
loop: loop:
- '' - ''
- '.sha256sum' - '.sha256sum'
- name: Taint nodes with cilium agent-not-ready
command: kubectl taint nodes --all node.cilium.io/agent-not-ready=true:NoExecute
when:
- kubernetes_pod_network.cni == 'cilium'
- not kubernetes_init_stat.stat.exists
register: cilium_taint
changed_when: "'tainted' in cilium_taint.stdout"
until: cilium_taint is not failed
retries: 12
delay: 5
- name: Configure Cilium networking - name: Configure Cilium networking
command: /usr/local/bin/cilium install --version {{ kubernetes_cilium_version }} --datapath-mode {{ kubernetes_cilium_datapath }} command: /usr/local/bin/cilium install --version {{ kubernetes_cilium_version }} --datapath-mode {{ kubernetes_cilium_datapath }}
when: when:
- kubernetes_pod_network.cni == 'cilium' - kubernetes_pod_network.cni == 'cilium'
- not kubernetes_init_stat.stat.exists - not kubernetes_init_stat.stat.exists
register: cilium_result
changed_when: "'Error' not in cilium_result.stdout"
until: cilium_result is not failed
retries: 20
delay: 5
- name: Configure Flannel networking. - name: Configure Flannel networking.
command: "kubectl apply -f {{ kubernetes_flannel_manifest_file }}" command: "kubectl apply -f {{ kubernetes_flannel_manifest_file }}"