kube-forge v2: embede python with ansible (kubespray) and cobra as cli building tool

This commit is contained in:
2025-06-22 00:37:47 +03:00
parent c2df2abc78
commit 4142a9db61
830 changed files with 874 additions and 2047 deletions

View File

@@ -0,0 +1,36 @@
---
- name: Wait for cilium
when:
- needs_cordoning | default(false)
- kube_network_plugin == 'cilium'
command: >
{{ kubectl }}
wait pod -n kube-system -l k8s-app=cilium
--field-selector 'spec.nodeName=={{ kube_override_hostname | default(inventory_hostname) }}'
--for=condition=Ready
--timeout={{ upgrade_post_cilium_wait_timeout }}
delegate_to: "{{ groups['kube_control_plane'][0] }}"
- name: Confirm node uncordon
pause:
echo: true
prompt: "Ready to uncordon node?"
when:
- upgrade_node_post_upgrade_confirm
- name: Wait before uncordoning node
pause:
seconds: "{{ upgrade_node_post_upgrade_pause_seconds }}"
when:
- not upgrade_node_post_upgrade_confirm
- upgrade_node_post_upgrade_pause_seconds != 0
- name: Run post upgrade hooks before uncordon
loop: "{{ post_upgrade_hooks | default([]) }}"
ansible.builtin.include_tasks: "{{ item }}"
- name: Uncordon node
command: "{{ kubectl }} uncordon {{ kube_override_hostname | default(inventory_hostname) }}"
delegate_to: "{{ groups['kube_control_plane'][0] }}"
when:
- needs_cordoning | default(false)