diff options
author | Kjetil Orbekk <kjetil.orbekk@gmail.com> | 2017-11-23 21:27:15 -0500 |
---|---|---|
committer | Bjørn Forsman <bjorn.forsman@gmail.com> | 2017-11-25 11:23:56 +0100 |
commit | a2dc37c7d1390d8aad8e2d888feb5bcd28656f4a (patch) | |
tree | 038f209a24ce5b85c863e732044f400e7ff09a41 /pkgs/servers/monitoring/munin | |
parent | c164d835364ab0b366eade41e67e6ecfab56af7a (diff) | |
download | nixlib-a2dc37c7d1390d8aad8e2d888feb5bcd28656f4a.tar nixlib-a2dc37c7d1390d8aad8e2d888feb5bcd28656f4a.tar.gz nixlib-a2dc37c7d1390d8aad8e2d888feb5bcd28656f4a.tar.bz2 nixlib-a2dc37c7d1390d8aad8e2d888feb5bcd28656f4a.tar.lz nixlib-a2dc37c7d1390d8aad8e2d888feb5bcd28656f4a.tar.xz nixlib-a2dc37c7d1390d8aad8e2d888feb5bcd28656f4a.tar.zst nixlib-a2dc37c7d1390d8aad8e2d888feb5bcd28656f4a.zip |
munin-node: patch to configure plugin-conf.d
Add a new patch (adding_sconfdir_munin-node.patch) to be able to configure the location of plugin-conf.d (otherwise it has to be configured at build time). This patch is very similar to the existing 'adding_servicedir_munin-node.patch'.
Diffstat (limited to 'pkgs/servers/monitoring/munin')
-rw-r--r-- | pkgs/servers/monitoring/munin/adding_sconfdir_munin-node.patch | 41 | ||||
-rw-r--r-- | pkgs/servers/monitoring/munin/default.nix | 1 |
2 files changed, 42 insertions, 0 deletions
diff --git a/pkgs/servers/monitoring/munin/adding_sconfdir_munin-node.patch b/pkgs/servers/monitoring/munin/adding_sconfdir_munin-node.patch new file mode 100644 index 000000000000..6e14d6137034 --- /dev/null +++ b/pkgs/servers/monitoring/munin/adding_sconfdir_munin-node.patch @@ -0,0 +1,41 @@ +commit af5fa3623bb9a73052f9154be4a0f38c60ea42a2 +Author: Kjetil Orbekk <kjetil.orbekk@gmail.com> +Date: Thu Nov 23 21:21:36 2017 -0500 + + node: add --sconfdir to set plugin configuration dir + +diff --git a/node/sbin/munin-node b/node/sbin/munin-node +index 909c8c4e..0ccf3941 100755 +--- a/node/sbin/munin-node ++++ b/node/sbin/munin-node +@@ -100,9 +100,11 @@ sub parse_args + my @ORIG_ARGV = @ARGV; + + my $servicedir_cmdline; ++ my $sconfdir_cmdline; + print_usage_and_exit() unless GetOptions( + "config=s" => \$conffile, + "servicedir=s" => \$servicedir_cmdline, ++ "sconfdir=s" => \$sconfdir_cmdline, + "debug!" => \$DEBUG, + "pidebug!" => \$PIDEBUG, + "paranoia!" => \$paranoia, +@@ -112,6 +114,7 @@ sub parse_args + + # We untaint the args brutally, since the sysadm should know what he does + $servicedir = $1 if defined $servicedir_cmdline && $servicedir_cmdline =~ m/(.*)/; ++ $sconfdir = $1 if defined $sconfdir_cmdline && $sconfdir_cmdline =~ m/(.*)/; + + # Reset ARGV (for HUPing) + @ARGV = @ORIG_ARGV; +@@ -175,6 +178,10 @@ Use E<lt>fileE<gt> as configuration file. [@@CONFDIR@@/munin-node.conf] + + Override plugin directory [@@CONFDIR@@/plugins/] + ++=item B<< --sconfdir <dir> >> ++ ++Override plugin configuration directory [@@CONFDIR@@/plugin-conf.d/] ++ + =item B< --[no]paranoia > + + Only run plugins owned by root. Check permissions as well. [--noparanoia] diff --git a/pkgs/servers/monitoring/munin/default.nix b/pkgs/servers/monitoring/munin/default.nix index 078c2318eef9..77e7b66fc39c 100644 --- a/pkgs/servers/monitoring/munin/default.nix +++ b/pkgs/servers/monitoring/munin/default.nix @@ -68,6 +68,7 @@ stdenv.mkDerivation rec { # https://github.com/munin-monitoring/munin/pull/134 ./adding_servicedir_munin-node.patch + ./adding_sconfdir_munin-node.patch ./preserve_environment.patch ]; |