Merge pull request #3993 from stoned/inventory-script-all-group-fix
Avoid duplicates of the 'all' group when using inventory script.
This commit is contained in:
commit
0c29807ba3
1 changed files with 4 additions and 1 deletions
|
@ -72,7 +72,10 @@ class InventoryScript(object):
|
|||
self.host_vars_from_top = data['hostvars']
|
||||
continue
|
||||
|
||||
group = groups[group_name] = Group(group_name)
|
||||
if group_name != all.name:
|
||||
group = groups[group_name] = Group(group_name)
|
||||
else:
|
||||
group = all
|
||||
host = None
|
||||
|
||||
if not isinstance(data, dict):
|
||||
|
|
Loading…
Reference in a new issue