Commit ef1ae4db by James Cammarata

Load group_vars for new groups loaded via add_host

Fixes #8605
parent 789196b2
......@@ -83,6 +83,7 @@ class ActionModule(object):
if not inventory.get_group(group_name):
new_group = Group(group_name)
inventory.add_group(new_group)
new_group.vars = inventory.get_group_variables(group_name, vault_password=inventory._vault_password)
grp = inventory.get_group(group_name)
grp.add_host(new_host)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment