diff --git a/tasks/main.yml b/tasks/main.yml index a6cdad4..59d77a1 100644 --- a/tasks/main.yml +++ b/tasks/main.yml @@ -112,7 +112,7 @@ - not kubernetes_init_stat.stat.exists - name: Allow pods on control plane (if configured). - command: "kubectl taint nodes --all node-role.kubernetes.io/control-plane-" + command: "kubectl taint nodes {{ item.inventory_hostname_short }} node-role.kubernetes.io/control-plane-" register: taint_removed until: > ("untainted" in taint_removed.stdout) or @@ -121,6 +121,7 @@ failed_when: false retries: 100 delay: 5 + loop: "{{ groups['k8s_control_plane'] }}" when: - join_ctrl_plane.changed - inventory_hostname == groups['k8s_control_plane'][0]