aboutsummaryrefslogtreecommitdiff
path: root/pkgs/monitoring-plugins
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/monitoring-plugins')
-rw-r--r--pkgs/monitoring-plugins/default.nix33
1 files changed, 33 insertions, 0 deletions
diff --git a/pkgs/monitoring-plugins/default.nix b/pkgs/monitoring-plugins/default.nix
new file mode 100644
index 0000000..852d29b
--- /dev/null
+++ b/pkgs/monitoring-plugins/default.nix
@@ -0,0 +1,33 @@
1{ stdenv, iputils, fetchpatch, fetchurl, file, hostname, perl, openssl,
2 bind, openldap, procps-ng, postfix,
3 wrapperDir ? "/run/wrappers/bin"
4}:
5stdenv.mkDerivation rec {
6 pname = "monitoring-plugins";
7 version = "2.2";
8 name = "${pname}-${version}";
9
10 src = fetchurl {
11 url = "https://www.monitoring-plugins.org/download/${name}.tar.gz";
12 sha256 = "0r9nvnk64nv7k8w352n99lw4p92pycxd9wlga9zyzjx9027m6si9";
13 };
14
15 patches = [
16 (fetchpatch {
17 name = "mariadb.patch";
18 url = "https://git.archlinux.org/svntogit/community.git/plain/trunk/0001-mariadb.patch?h=packages/monitoring-plugins";
19 sha256 = "0jf6fqkyzag66rid92m7asnr2dp8rr8kn4zjvhqg0mqvf8imppky";
20 })
21 ];
22
23 # ping needs CAP_NET_RAW capability which is set only in the wrappers namespace
24 configurePhase = ''
25 ./configure --disable-static --disable-dependency-tracking \
26 --prefix=$out \
27 --with-ping-command="${wrapperDir}/ping -4 -n -U -w %d -c %d %s" \
28 --with-ping6-command="${wrapperDir}/ping -6 -n -U -w %d -c %d %s" \
29 --with-sudo-command="${wrapperDir}/sudo"
30 '';
31
32 buildInputs = [ perl file hostname iputils openssl openldap procps-ng bind.dnsutils postfix ];
33}