Compare commits

...

3 Commits

Author SHA1 Message Date
Dustin ddafc09839 dch-gw: Open Zabbix ports in the firewall
Obviously, the Zabbix agent (active and passive) ports need to be open
in order for the gateway device itself to be monitored by Zabbix.
2018-06-19 20:41:45 -05:00
Dustin 5188250cfc hosts: Add dch-gw to zabbix group
The gateway device is now monitored by Zabbix. Adding it to the *zabbix*
group ensures that the Zabbix agent is installed and configured
correctly.

Because the *zabbix-agent* role has a task to configure FirewallD, the
`host_uses_firewalld` variable needs to be set to `false` for *gw0*,
since it does not use FirewallD.
2018-06-19 20:40:58 -05:00
Dustin f78fe14eae roles/zabbix: Respect host_uses_firewalld
For machines that do not use firewalld, the *zabbix-agent* role will now
skip attempting to open the Zabbix agent port using the `firewalld`
module. The `host_uses_firewalld` variable controls this behavior.
2018-06-19 20:37:09 -05:00
4 changed files with 7 additions and 0 deletions

View File

@ -85,6 +85,8 @@ allow_incoming:
port: bootps
- protocol: tcp
port: ssh
- protocol: tcp
port: 10050
allow_outgoing:
@ -106,5 +108,7 @@ allow_outgoing:
port: domain
- protocol: udp
port: ntp
- protocol: tcp
port: 10051
trace_dropped: true

1
host_vars/gw0/main.yml Normal file
View File

@ -0,0 +1 @@
host_uses_firewalld: false

1
hosts
View File

@ -67,4 +67,5 @@ zabbix-server
zbx0.pyrocufflink.blue
[zabbix:children]
dch-gw
pyrocufflink

View File

@ -34,6 +34,7 @@
state=enabled
tags:
- firewalld
when: host_uses_firewalld|d(true)
notify: save firewalld configuration
- name: ensure zabbix agent starts at boot