Skip to content

Commit

Permalink
Fix Ansible inventory sync to call default job lookup method only if …
Browse files Browse the repository at this point in the history
…needed
  • Loading branch information
tpapaioa committed Feb 13, 2024
1 parent 94476f4 commit eaaf079
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion broker/providers/ansible_tower.py
Original file line number Diff line number Diff line change
Expand Up @@ -366,7 +366,9 @@ def _compile_host_info(self, host):
)

# Get broker_args from host facts if present
broker_args = getattr(host_facts, "_broker_args", self._get_broker_args_from_job(host))
broker_args = getattr(host_facts, "_broker_args", None) or self._get_broker_args_from_job(
host
)

host_info = {
"name": host.name,
Expand Down

0 comments on commit eaaf079

Please sign in to comment.