diff --git a/tasks/main.yml b/tasks/main.yml index 38e588b799d1906cf26177454ba36160fbe5f3b3..18c388f40f5a44535a975ee189202057edfa2b5d 100644 --- a/tasks/main.yml +++ b/tasks/main.yml @@ -3,7 +3,7 @@ - name: "Zabbix Agent Role" set_fact: role_zabbix_agent_started=true - tags: always + tags: 'always' - block: @@ -12,13 +12,15 @@ path: '/etc/init.d/zabbix-agent' register: zabbix_available - - import_tasks: install.yml + - include_tasks: install.yml when: not zabbix_available.stat.exists + tags: 'always' - - import_tasks: config.yml + - include_tasks: config.yml + tags: 'always' - name: 'Remember that this role had been run' set_fact: role_zabbix_agent_completed=true - tags: always + tags: 'always' when: '"zabbix_agent" not in excluded_roles and role_zabbix_agent_completed is not defined'