Use hostname in group_by_aws_account to prevent duplicates. (#34053)
Fix typo. The use of `dest` for group_by_aws_account causes the group to be produced using IP and to duplicate the hosts in the inventory. Fixes #23772 Signed-off-by: bo <robert@jbanetwork.com>
This commit is contained in:
parent
bf8d695ec3
commit
b5c0141fb0
1 changed files with 1 additions and 1 deletions
|
@ -1026,7 +1026,7 @@ class Ec2Inventory(object):
|
||||||
|
|
||||||
# Inventory: Group by AWS account ID
|
# Inventory: Group by AWS account ID
|
||||||
if self.group_by_aws_account:
|
if self.group_by_aws_account:
|
||||||
self.push(self.inventory, self.aws_account_id, dest)
|
self.push(self.inventory, self.aws_account_id, hostname)
|
||||||
if self.nested_groups:
|
if self.nested_groups:
|
||||||
self.push_group(self.inventory, 'accounts', self.aws_account_id)
|
self.push_group(self.inventory, 'accounts', self.aws_account_id)
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue