2021-12-01 19:13:34 +01:00
|
|
|
---
|
|
|
|
- name: Deploy Zabbix Agent configuration
|
2022-01-24 12:00:19 +01:00
|
|
|
template: src=zabbix_agentd.conf.j2 dest=/etc/zabbix/{{ zabbix_agent2 | ternary('zabbix_agent2.conf', 'zabbix_agentd.conf') }}
|
2021-12-01 19:13:34 +01:00
|
|
|
notify: restart zabbix-agent
|
|
|
|
tags: zabbix
|
|
|
|
|
|
|
|
- name: Detect if vfs.dev.discovery is supported natively
|
2022-01-24 12:00:19 +01:00
|
|
|
shell: "{{ zabbix_agent2 | ternary('zabbix_agent2', 'zabbix_agentd') }} -t vfs.dev.discovery -c /dev/null | grep -q ZBX_NOTSUPPORTED"
|
2021-12-01 19:13:34 +01:00
|
|
|
register: zabbix_dev_disco
|
|
|
|
failed_when: False
|
|
|
|
changed_when: False
|
|
|
|
tags: zabbix
|
|
|
|
|
|
|
|
- name: Handle block dev discovery config
|
|
|
|
template: src=block_devices.conf.j2 dest=/etc/zabbix/zabbix_agentd.conf.d/block_devices.conf
|
|
|
|
notify: restart zabbix-agent
|
|
|
|
tags: zabbix
|