mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-07-02 14:40:19 -07:00
Correct issue of handlers running on all hosts incorrectly
Also adds an integration test to catch this bug in the future. Fixes #7559
This commit is contained in:
parent
617e7eaf5b
commit
cfd8c685d1
4 changed files with 24 additions and 9 deletions
|
@ -355,7 +355,7 @@ class PlayBook(object):
|
|||
def _run_task_internal(self, task):
|
||||
''' run a particular module step in a playbook '''
|
||||
|
||||
hosts = self._trim_unavailable_hosts(task.play._play_hosts)
|
||||
hosts = self._trim_unavailable_hosts(self.inventory.list_hosts(task.play._play_hosts))
|
||||
self.inventory.restrict_to(hosts)
|
||||
|
||||
runner = ansible.runner.Runner(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue