mirror of
https://github.com/ansible-collections/community.general.git
synced 2024-09-14 20:13:21 +02:00
Merge pull request #2261 from bcoca/groupby_2186
now group by module invalidates host cached variables
This commit is contained in:
commit
b6f7a22de5
1 changed files with 1 additions and 0 deletions
|
@ -71,6 +71,7 @@ class ActionModule(object):
|
|||
inv_group = ansible.inventory.Group(name=group)
|
||||
inventory.add_group(inv_group)
|
||||
for host in hosts:
|
||||
del self.runner.inventory._vars_per_host[host]
|
||||
inv_host = inventory.get_host(host)
|
||||
if not inv_host:
|
||||
inv_host = ansible.inventory.Host(name=host)
|
||||
|
|
Loading…
Reference in a new issue