From cf37e8428fce4d7084cac6b1f267581e7906d601 Mon Sep 17 00:00:00 2001 From: Jesse Pretorius Date: Tue, 24 Jul 2018 18:42:55 +0100 Subject: [PATCH] Use run_once instead of a group that does not exist The var keystone_services['keystone-api']['group'] is not defined. While I have no idea why the task wasn't failing outright due to that, it was having some rather unwanted side-effects - like running on all keystone containers. Given that keystone only has one group, we can just use run_once instead. Change-Id: Iad494d503bb04741b3b0ea461d8a9ce1988b24c7 --- tasks/main.yml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/tasks/main.yml b/tasks/main.yml index dc8f26fc..4639bcd0 100644 --- a/tasks/main.yml +++ b/tasks/main.yml @@ -103,9 +103,7 @@ - keystone-config - include_tasks: mq_setup.yml - when: - - "keystone_services['keystone-api']['group'] in group_names" - - "inventory_hostname == ((groups[keystone_services['keystone-api']['group']]| intersect(ansible_play_hosts)) | list)[0]" + run_once: yes with_items: - oslomsg_setup_host: "{{ keystone_oslomsg_rpc_setup_host }}" oslomsg_userid: "{{ keystone_oslomsg_rpc_userid }}"