From 598968096756a65a58ab8a0450cdad418de08560 Mon Sep 17 00:00:00 2001 From: Florent Monbillard <f.monbillard@gmail.com> Date: Fri, 18 Sep 2020 20:14:27 -0400 Subject: [PATCH] Make sure node_ip is set if node is in etcd group (#6719) --- roles/remove-node/remove-etcd-node/tasks/main.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/roles/remove-node/remove-etcd-node/tasks/main.yml b/roles/remove-node/remove-etcd-node/tasks/main.yml index 3351e2038..4d739729d 100644 --- a/roles/remove-node/remove-etcd-node/tasks/main.yml +++ b/roles/remove-node/remove-etcd-node/tasks/main.yml @@ -21,6 +21,8 @@ assert: that: node_ip is defined and node_ip | length > 0 msg: "Etcd node ip is not set !" + when: + - inventory_hostname in groups['etcd'] - name: Lookup etcd member id shell: "{{ bin_dir }}/etcdctl member list | grep {{ node_ip }} | cut -d, -f1" -- GitLab