mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-07-22 12:50:22 -07:00
Store the list of hosts to run on in runner object
This reduces the number of times inventory.list_hosts is called, which can be costly. When coming from a playbook that data is already known.
This commit is contained in:
parent
e8ad36c8d4
commit
6013f0738e
2 changed files with 11 additions and 3 deletions
|
@ -316,7 +316,8 @@ class PlayBook(object):
|
|||
check=self.check, diff=self.diff, environment=task.environment, complex_args=task.args,
|
||||
accelerate=task.play.accelerate, accelerate_port=task.play.accelerate_port,
|
||||
accelerate_ipv6=task.play.accelerate_ipv6,
|
||||
error_on_undefined_vars=C.DEFAULT_UNDEFINED_VAR_BEHAVIOR
|
||||
error_on_undefined_vars=C.DEFAULT_UNDEFINED_VAR_BEHAVIOR,
|
||||
run_hosts=hosts
|
||||
)
|
||||
|
||||
if task.async_seconds == 0:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue