mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-04-26 04:11:25 -07:00
Merge pull request #356 from jkleint/singleton-notify
Support single handlers for notify.
This commit is contained in:
commit
dab50574e0
1 changed files with 2 additions and 0 deletions
|
@ -364,6 +364,8 @@ class PlayBook(object):
|
||||||
# we would only trigger restarting Apache on half of the nodes
|
# we would only trigger restarting Apache on half of the nodes
|
||||||
|
|
||||||
subtasks = task.get('notify', [])
|
subtasks = task.get('notify', [])
|
||||||
|
if isinstance(subtasks, basestring):
|
||||||
|
subtasks = [subtasks]
|
||||||
if len(subtasks) > 0:
|
if len(subtasks) > 0:
|
||||||
for host, results in results.get('contacted',{}).iteritems():
|
for host, results in results.get('contacted',{}).iteritems():
|
||||||
if results.get('changed', False):
|
if results.get('changed', False):
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue