From 6f4dc0fead52074a76b3a098dea89780efe6b3e7 Mon Sep 17 00:00:00 2001 From: Fabian Schlenz Date: Wed, 25 Nov 2020 06:29:57 +0100 Subject: [PATCH] You can now put a custom config file snippet at /boot/config/plugins/zabbix_agent/zabbix_agentd.custom.conf. --- files/boot/config/plugins/zabbix_agent/zabbix_agentd.conf | 4 ++++ zabbix_agent.plg | 7 +++++++ 2 files changed, 11 insertions(+) diff --git a/files/boot/config/plugins/zabbix_agent/zabbix_agentd.conf b/files/boot/config/plugins/zabbix_agent/zabbix_agentd.conf index ef73b79..e1c58fb 100644 --- a/files/boot/config/plugins/zabbix_agent/zabbix_agentd.conf +++ b/files/boot/config/plugins/zabbix_agent/zabbix_agentd.conf @@ -19,6 +19,8 @@ AllowKey=vfs.fs.*[*] AllowKey=vm.memory.size[*] AllowKey=unraid.* AllowKey=unraid.*[*] +AllowKey=custom.* +AllowKey=custom.*[*] DenyKey=* @@ -29,3 +31,5 @@ UserParameter=unraid.qemu.discovery,/usr/local/emhttp/plugins/zabbix_agent/scrip UserParameter=unraid.qemu[*],/usr/local/emhttp/plugins/zabbix_agent/scripts/qemu.sh "$1" UserParameter=unraid.temperatures,/usr/local/emhttp/plugins/zabbix_agent/scripts/temperatures.sh UserParameter=unraid.ups,/usr/local/emhttp/plugins/zabbix_agent/scripts/ups.sh + +Include=/boot/config/plugins/zabbix_agent/*.custom.conf diff --git a/zabbix_agent.plg b/zabbix_agent.plg index 23de5ff..17b9de0 100644 --- a/zabbix_agent.plg +++ b/zabbix_agent.plg @@ -17,6 +17,13 @@ ## &name; +### version +- You can now add a custom zabbix agent configuration file at /boot/config/plugins/zabbix_agent/zabbix_agentd.custom.conf. + It won't be overwritten by a future update of this plugin. Please note that the list of usable keys is heavily restricted + in zabbix_agentd.conf. To have your custom UserParameters accessible, you can either: + - Name them custom.$whatever. + - Add the key to the whitelist via AllowKey. + ### 2010.10.31.1 - Updated zabbix_agentd from 5.0.2 to 5.0.3 - Download updated plugins from stable instead of main.