mirror of https://github.com/ansible/ansible.git
parent
7f04ee1eb4
commit
77befcf5d7
@ -0,0 +1,4 @@
|
|||||||
|
bugfixes:
|
||||||
|
- imports - Prevent the name of an import from being addressable as a handler, only the tasks within should
|
||||||
|
be addressable. Use an include instead of an import if you need to execute many tasks from a single handler
|
||||||
|
(https://github.com/ansible/ansible/issues/48936)
|
@ -0,0 +1,11 @@
|
|||||||
|
- hosts: localhost
|
||||||
|
gather_facts: false
|
||||||
|
tasks:
|
||||||
|
- import_role:
|
||||||
|
name: include_handler_test
|
||||||
|
|
||||||
|
- hosts: localhost
|
||||||
|
gather_facts: false
|
||||||
|
tasks:
|
||||||
|
- import_role:
|
||||||
|
name: import_handler_test
|
@ -0,0 +1,2 @@
|
|||||||
|
- name: do_import
|
||||||
|
import_tasks: tasks/handlers.yml
|
@ -0,0 +1,2 @@
|
|||||||
|
- debug:
|
||||||
|
msg: import handler task
|
@ -0,0 +1,3 @@
|
|||||||
|
- command: "true"
|
||||||
|
notify:
|
||||||
|
- do_import
|
@ -0,0 +1,2 @@
|
|||||||
|
- name: do_include
|
||||||
|
include_tasks: tasks/handlers.yml
|
@ -0,0 +1,2 @@
|
|||||||
|
- debug:
|
||||||
|
msg: include handler task
|
@ -0,0 +1,3 @@
|
|||||||
|
- command: "true"
|
||||||
|
notify:
|
||||||
|
- do_include
|
Loading…
Reference in New Issue