mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-02 15:41:48 +00:00
nixos/zabbixAgent: add a few minor tweaks to make configuration file compatible with both zabbix agent 1 and 2
This commit is contained in:
parent
debbd84333
commit
d6fd7c6613
@ -128,11 +128,16 @@ in
|
||||
{
|
||||
LogType = "console";
|
||||
Server = cfg.server;
|
||||
ListenIP = cfg.listen.ip;
|
||||
ListenPort = cfg.listen.port;
|
||||
LoadModule = builtins.attrNames cfg.modules;
|
||||
}
|
||||
(mkIf (cfg.modules != {}) { LoadModulePath = "${moduleEnv}/lib"; })
|
||||
(mkIf (cfg.modules != {}) {
|
||||
LoadModule = builtins.attrNames cfg.modules;
|
||||
LoadModulePath = "${moduleEnv}/lib";
|
||||
})
|
||||
|
||||
# the default value for "ListenIP" is 0.0.0.0 but zabbix agent 2 cannot accept configuration files which
|
||||
# explicitly set "ListenIP" to the default value...
|
||||
(mkIf (cfg.listen.ip != "0.0.0.0") { ListenIP = cfg.listen.ip; })
|
||||
];
|
||||
|
||||
networking.firewall = mkIf cfg.openFirewall {
|
||||
|
Loading…
Reference in New Issue
Block a user