From 00562a2cda412d4e0220c85c95175d4e99848a22 Mon Sep 17 00:00:00 2001 From: Igor Duarte Date: Mon, 1 Apr 2024 13:11:43 +0200 Subject: [PATCH] test --- ansible-scylla-node/tasks/common.yml | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/ansible-scylla-node/tasks/common.yml b/ansible-scylla-node/tasks/common.yml index eac5f969..115f61a5 100644 --- a/ansible-scylla-node/tasks/common.yml +++ b/ansible-scylla-node/tasks/common.yml @@ -318,6 +318,12 @@ set_fact: broadcast_address: "{{ scylla_broadcast_address }}" +# This will be used later to validate the output of nodetool status +- name: Create a list with the broadcast addresses of the nodes in play_hosts + broadcast_address_list: "{{ broadcast_address_list | default([]) + [hostvars[item]['broadcast_address']] }}" + loop: "{{ play_hosts }}" + run_once: true + - name: start_scylla_service dependent tasks block: - name: Generate tokens for the new nodes @@ -347,7 +353,7 @@ - name: wait for the cluster to become healthy shell: | - nodetool status|grep -E '^UN|^UJ|^DN'| grep -Ew "{{ play_hosts | join('|') }}" | wc -l + nodetool status|grep -E '^UN|^UJ|^DN'| grep -Ew "{{ broadcast_address_list | join('|') }}" | wc -l register: node_count until: node_count.stdout|int == play_hosts|length retries: "{{ scylla_bootstrap_wait_time_sec|int }}"