Skip to content

Commit

Permalink
Merge pull request #669 from alexjfisher/fix_proxy_idempotency
Browse files Browse the repository at this point in the history
Fix zabbix::proxy idempotency
  • Loading branch information
ekohl authored Apr 13, 2020
2 parents 944d202 + 3d8dd4b commit dbffa0e
Showing 1 changed file with 14 additions and 6 deletions.
20 changes: 14 additions & 6 deletions manifests/proxy.pp
Original file line number Diff line number Diff line change
Expand Up @@ -449,12 +449,20 @@
# is set to false, you'll get warnings like this:
# "Warning: You cannot collect without storeconfigs being set"
if $manage_resources {
class { 'zabbix::resources::proxy':
hostname => $hostname,
ipaddress => $listen_ip,
use_ip => $use_ip,
mode => $mode,
port => $listenport,
if String($mode) == '0' {
# Active proxies don't use `ipaddress`, `use_ip` or `port`.
class { 'zabbix::resources::proxy':
hostname => $hostname,
mode => $mode,
}
} else {
class { 'zabbix::resources::proxy':
hostname => $hostname,
ipaddress => $listen_ip,
use_ip => $use_ip,
mode => $mode,
port => $listenport,
}
}

zabbix::userparameters { 'Zabbix_Proxy': template => 'Template App Zabbix Proxy', }
Expand Down

0 comments on commit dbffa0e

Please sign in to comment.