11 lines
413 B
YAML
11 lines
413 B
YAML
---
|
|
- name: Delete node
|
|
command: "{{ bin_dir }}/kubectl delete node {{ kube_override_hostname|default(inventory_hostname) }}"
|
|
delegate_to: "{{ groups['kube_control_plane']|first }}"
|
|
when: inventory_hostname in groups['k8s_cluster']
|
|
retries: 10
|
|
# Sometimes the api-server can have a short window of indisponibility when we delete a master node
|
|
delay: 3
|
|
register: result
|
|
until: result is not failed
|