Fix synchronize lookup of localhost info
This commit is contained in:
parent
50448d68e1
commit
017bd7b1cd
1 changed files with 4 additions and 1 deletions
|
@ -82,7 +82,10 @@ class ActionModule(ActionBase):
|
||||||
del task_vars[key]
|
del task_vars[key]
|
||||||
|
|
||||||
# Add the definitions from localhost
|
# Add the definitions from localhost
|
||||||
localhost = task_vars['hostvars']['127.0.0.1']
|
for host in C.LOCALHOST:
|
||||||
|
if host in task_vars['hostvars']:
|
||||||
|
localhost = task_vars['hostvars'][host]
|
||||||
|
break
|
||||||
if 'ansible_syslog_facility' in localhost:
|
if 'ansible_syslog_facility' in localhost:
|
||||||
task_vars['ansible_syslog_facility'] = localhost['ansible_syslog_facility']
|
task_vars['ansible_syslog_facility'] = localhost['ansible_syslog_facility']
|
||||||
for key in localhost:
|
for key in localhost:
|
||||||
|
|
Loading…
Reference in a new issue