git.iko.soy/typeable/nixpkgs
on master help sign in
check_systemd: init at 2.2.1

and remove pynagsystemd, which it replaces.

commit590aa37109eb06a9cc00f7854edde670f4e66d1a authorSymphorien Gibol <symphorien+git@xlumurb.eu> dateSat 24 Oct 2020, 12:00 (6 years ago) parent1dc3737
4 files changed+38−23
pkgs/servers/monitoring/nagios/plugins/check_systemd.nix+36 pkgs/servers/monitoring/nagios/plugins/pynagsystemd.nix−22 pkgs/top-level/aliases.nix+1 pkgs/top-level/all-packages.nix+1−1
pkgs/servers/monitoring/nagios/plugins/check_systemd.nixnew file+36
@@ -0,0 +1,36 @@
1+{ fetchFromGitHub, python3Packages, lib }:
2+
3+python3Packages.buildPythonApplication rec {
4+ pname = "check_systemd";
5+ version = "2.2.1";
6+
7+ src = fetchFromGitHub {
8+ owner = "Josef-Friedrich";
9+ repo = pname;
10+ rev = "v${version}";
11+ sha256 = "04r14dhqzrdndn235dvr6afy4s4g4asynsgvj99cmyq55nah4asn";
12+ };
13+
14+ propagatedBuildInputs = with python3Packages; [ nagiosplugin ];
15+
16+ postInstall = ''
17+ # check_systemd is only a broken stub calling check_systemd.py
18+ mv $out/bin/check_systemd{.py,}
19+ '';
20+
21+ # the test scripts run ./check_systemd.py and check_systemd. Patch to
22+ # the installed, patchShebanged executable in $out/bin
23+ preCheck = ''
24+ find test -name "*.py" -execdir sed -i "s@./check_systemd.py@$out/bin/check_systemd@" '{}' ";"
25+ export PATH=$PATH:$out/bin
26+ '';
27+ checkInputs = [ python3Packages.pytestCheckHook ];
28+
29+ meta = with lib; {
30+ description = "Nagios / Icinga monitoring plugin to check systemd for failed units";
31+ inherit (src.meta) homepage;
32+ maintainers = with maintainers; [ symphorien ];
33+ license = licenses.lgpl2Only;
34+ platforms = platforms.linux;
35+ };
36+}
pkgs/servers/monitoring/nagios/plugins/pynagsystemd.nixdeleted−22
@@ -1,22 +0,0 @@
1−{ fetchFromGitHub, python3Packages, lib }:
2−
3−python3Packages.buildPythonApplication rec {
4− pname = "pynagsystemd";
5− version = "1.2.0";
6−
7− src = fetchFromGitHub {
8− owner = "kbytesys";
9− repo = pname;
10− rev = "v${version}";
11− sha256 = "1xjhkhdpmqa7ngcpcfhrkmj4cid2wla3fzgr04wvw672ysffv2vz";
12− };
13−
14− propagatedBuildInputs = with python3Packages; [ nagiosplugin ];
15−
16− meta = with lib; {
17− description = "Simple and easy nagios check for systemd status";
18− homepage = "https://github.com/kbytesys/pynagsystemd";
19− maintainers = with maintainers; [ symphorien ];
20− license = licenses.gpl2;
21− };
22−}
pkgs/top-level/aliases.nix+1
@@ -463,6 +463,7 @@ mapAliases ({
463463 phonon-backend-gstreamer = throw "phonon-backend-gstreamer: Please use libsForQt5.phonon-backend-gstreamer, as Qt4 support in this package has been removed."; # added 2019-11-22
464464 phonon-backend-vlc = throw "phonon-backend-vlc: Please use libsForQt5.phonon-backend-vlc, as Qt4 support in this package has been removed."; # added 2019-11-22
465465 phonon = throw "phonon: Please use libsForQt5.phonon, as Qt4 support in this package has been removed."; # added 2019-11-22
466+ pynagsystemd = throw "pynagsystemd was removed as it was unmaintained and incompatible with recent systemd versions. Instead use its fork check_systemd."; # added 2020-10-24
466467 qca-qt5 = libsForQt5.qca-qt5; # added 2015-12-19
467468 quake3game = ioquake3; # added 2016-01-14
468469 qvim = throw "qvim has been removed."; # added 2020-08-31
pkgs/top-level/all-packages.nix+1−1
@@ -16958,7 +16958,7 @@ in
1695816958
1695916959 checkSSLCert = callPackage ../servers/monitoring/nagios/plugins/check_ssl_cert.nix { };
1696016960
16961− pynagsystemd = callPackage ../servers/monitoring/nagios/plugins/pynagsystemd.nix { };
16961+ check_systemd = callPackage ../servers/monitoring/nagios/plugins/check_systemd.nix { };
1696216962
1696316963 neo4j = callPackage ../servers/nosql/neo4j { };
1696416964