Improve inventory scoping for limited play execution

When executing the playbook with limits set, the scoping
currently does not work quite as well as one would hope.

This tightens it a bit more to ensure that it operates
as expected.

Change-Id: Ie043fca77d98ce55edb84547b06be0001d7311ea
This commit is contained in:
Jesse Pretorius 2017-07-06 12:55:38 +01:00 committed by Jesse Pretorius (odyssey4me)
parent 0e2b011ac7
commit 1335990b9a

View File

@ -52,7 +52,7 @@
static: no
when:
- "'glance_api' in group_names"
- "inventory_hostname == ansible_play_hosts[0]"
- "inventory_hostname == (groups['glance_api'] | intersect(ansible_play_hosts))[0]"
tags:
- glance-config
@ -60,7 +60,7 @@
static: no
when:
- "'glance_api' in group_names"
- "inventory_hostname == ansible_play_hosts[0]"
- "inventory_hostname == (groups['glance_api'] | intersect(ansible_play_hosts))[0]"
tags:
- glance-config