关于include的问题
---
- hosts: test
tasks:
- include: test_tasks.yml
handlers:
- include: test_handlers.yml
-----------------------------
test_tasks.yml
- name: install httpd
yum: pkg=httpd state=installed
notify:
- start httpd
-----------------------------
test_handlers.yml
- name: start httpd
service: name=httpd state=started
-----------------------------
代码如上所示,handlers加入include不执行启动操作
页:
[1]