mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-06 05:12:45 +00:00
added new play_hosts var
this variable has the 'current host list' to be executed over in the play. Useful when using --limit to not iterate over hosts not included in play in templates or with_items. Signed-off-by: Brian Coca <briancoca+dev@gmail.com>
This commit is contained in:
@@ -346,6 +346,8 @@ class PlayBook(object):
|
||||
run_hosts=hosts
|
||||
)
|
||||
|
||||
runner.module_vars.update({'play_hosts': hosts})
|
||||
|
||||
if task.async_seconds == 0:
|
||||
results = runner.run()
|
||||
else:
|
||||
|
||||
Reference in New Issue
Block a user