From b0097fd0c100827e5c1a3ccbde7044a8c9d53138 Mon Sep 17 00:00:00 2001 From: Hans Feldt <2808287+hafe@users.noreply.github.com> Date: Mon, 5 Oct 2020 21:55:21 +0200 Subject: [PATCH] harden reset to work in more cases (#6781) reset playbook fails and does not continue cleanup after for example a host reboot with kubelet stopped/disabled --- roles/reset/tasks/main.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/roles/reset/tasks/main.yml b/roles/reset/tasks/main.yml index 886fa9a41..03e2e63ea 100644 --- a/roles/reset/tasks/main.yml +++ b/roles/reset/tasks/main.yml @@ -147,6 +147,7 @@ warn: false check_mode: no register: mounted_dirs + failed_when: false tags: - mounts @@ -154,6 +155,7 @@ command: umount -f {{ item }} with_items: "{{ mounted_dirs.stdout_lines }}" register: umount_dir + when: mounted_dirs retries: 4 until: umount_dir.rc == 0 delay: 5