is "Configure zabbix-agent" reporting a change ?

Am Mittwoch, 21. Juni 2017 16:35:05 UTC+2 schrieb Onallion:
>
> Hi,
>
> I am running a playbook with a task that calls a handler like so:
> - name: "Configure zabbix-agent"
>   win_template:
>     src: zabbix_agentd.conf.j2
>     dest: C:\Program Files\Zabbix Agent\zabbix_agentd.conf
>     newline_sequence: '\n'
>     trim_blocks: no
>   notify: restart zabbix-agent
>
> The handler itself is:
>
> - name: restart zabbix-agent
>   win_service:
>     name: Zabbix Agent
>     state: restarted
>     start_mode: auto
>
> When I run the playbook there are no errors, but when it reaches the end 
> there is no mention of the handler and it doesn't run.
>
> The funny thing is, when I use the Linux equivalent and run it on a Linux 
> host, it does work:
>
> - name: restart zabbix-agent
>   service: name={{ zabbix_agent_service }}
>            state=restarted
>            enabled=yes
>   become: yes
>
> I could just set it as a task, but I don't want the playbook to restart 
> the service every time it runs, just when something changed.
> Any help appreciated
>

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to ansible-project+unsubscr...@googlegroups.com.
To post to this group, send email to ansible-project@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/97bcfc72-c198-45b7-9d47-30b8455de835%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to