Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix nagiosPlugins #351008

Merged
merged 6 commits into from
Oct 25, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

stdenv.mkDerivation {
pname = "check-uptime";
version = "unstable-2016-11-12";
version = "0-unstable-2016-11-12";

src = fetchFromGitHub {
owner = "madrisan";
Expand Down
63 changes: 36 additions & 27 deletions pkgs/servers/monitoring/nagios-plugins/labs_consol_de/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
autoreconfHook,
coreutils,
fetchFromGitHub,
fetchurl,
gnugrep,
gnused,
lib,
Expand All @@ -12,28 +11,16 @@
}:

let
glplugin = fetchFromGitHub {
owner = "lausser";
repo = "GLPlugin";
rev = "ef3107f01afe55fad5452e64ac5bbea00b18a8d5";
sha256 = "047fwrycsl2vmpi4wl46fs6f8y191d6qc9ms5rvmrj1dm2r828ws";
};

generic =
{
pname,
version,
sha256,
src,
description,
buildInputs,
}:
stdenv.mkDerivation {
inherit pname version;

src = fetchurl {
url = "https://labs.consol.de/assets/downloads/nagios/${pname}-${version}.tar.gz";
inherit sha256;
};
inherit pname version src;

buildInputs = [ perlPackages.perl ] ++ buildInputs;

Expand All @@ -42,9 +29,7 @@ let
makeWrapper
];

prePatch = ''
rm -rf GLPlugin
ln -s ${glplugin} GLPlugin
postPatch = ''
substituteInPlace plugins-scripts/Makefile.am \
--replace-fail /bin/cat ${lib.getExe' coreutils "cat"} \
--replace-fail /bin/echo ${lib.getExe' coreutils "echo"} \
Expand Down Expand Up @@ -74,26 +59,50 @@ let

in
{
check_mssql_health = generic {
check_mssql_health = generic rec {
pname = "check-mssql-health";
version = "2.6.4.15";
sha256 = "12z0b3c2p18viy7s93r6bbl8fvgsqh80136d07118qhxshp1pwxg";
version = "2.7.7";

src = fetchFromGitHub {
owner = "lausser";
repo = "check_mssql_health";
rev = "refs/tags/${version}";
hash = "sha256-K6sGrms9z59a9rkZNulwKBexGF2Nkqqak/cRg12ynxc=";
fetchSubmodules = true;
};

description = "Check plugin for Microsoft SQL Server";
buildInputs = [ perlPackages.DBDsybase ];
};

check_nwc_health = generic {
check_nwc_health = generic rec {
pname = "check-nwc-health";
version = "7.10.0.6";
sha256 = "092rhaqnk3403z0y60x38vgh65gcia3wrd6gp8mr7wszja38kxv2";
version = "11.7";

src = fetchFromGitHub {
owner = "lausser";
repo = "check_nwc_health";
rev = "refs/tags/${version}";
hash = "sha256-r8Cb9RnEohNp0GxMAIaj7e08dTWZhuV1jz4/b8tuJ6k=";
fetchSubmodules = true;
};

description = "Check plugin for network equipment";
buildInputs = [ perlPackages.NetSNMP ];
};

check_ups_health = generic {
check_ups_health = generic rec {
pname = "check-ups-health";
version = "2.8.3.3";
sha256 = "0qc2aglppwr9ms4p53kh9nr48625sqrbn46xs0k9rx5sv8hil9hm";
version = "4.3.1.1";

src = fetchFromGitHub {
owner = "lausser";
repo = "check_ups_health";
rev = "refs/tags/${version}";
hash = "sha256-ZGSTPVJObP49/tDASOCh4wVdMKajheHD+xVTiFf101k=";
fetchSubmodules = true;
};

description = "Check plugin for UPSs";
buildInputs = [ perlPackages.NetSNMP ];
};
Expand Down
22 changes: 11 additions & 11 deletions pkgs/top-level/aliases.nix
Original file line number Diff line number Diff line change
Expand Up @@ -177,17 +177,17 @@ mapAliases {
cawbird = throw "cawbird has been abandoned upstream and is broken anyways due to Twitter closing its API";
certmgr-selfsigned = certmgr; # Added 2023-11-30
challenger = taler-challenger; # Added 2024-09-04
check_smartmon = throw "'check_smartmon' has been renamed to 'nagiosPlugins.check_smartmon'"; # Added 2024-05-03
check_systemd = throw "'check_systemd' has been renamed to 'nagiosPlugins.check_systemd'"; # Added 2024-05-03
check_zfs = throw "'check_zfs' has been renamed to 'nagiosPlugins.check_zfs'"; # Added 2024-05-03
check-esxi-hardware = throw "'check-esxi-hardware' has been renamed to 'nagiosPlugins.check_esxi_hardware'"; # Added 2024-05-03
check-mssql-health = throw "'check-mssql-health' has been renamed to 'nagiosPlugins.check_mssql_health'"; # Added 2024-05-03
check-nwc-health = throw "'check-nwc-health' has been renamed to 'nagiosPlugins.check_nwc_health'"; # Added 2024-05-03
check-openvpn = throw "'check-openvpn' has been renamed to 'nagiosPlugins.check_openvpn'"; # Added 2024-05-03
check-ups-health = throw "'check-ups-health' has been renamed to 'nagiosPlugins.check_ups_health'"; # Added 2024-05-03
check-uptime = throw "'check-uptime' has been renamed to 'nagiosPlugins.check_uptime'"; # Added 2024-05-03
check-wmiplus = throw "'check-wmiplus' has been renamed to 'nagiosPlugins.check_wmi_plus'"; # Added 2024-05-03
checkSSLCert = throw "'checkSSLCert' has been renamed to 'nagiosPlugins.check_ssl_cert'"; # Added 2024-05-03
check_smartmon = nagiosPlugins.check_smartmon; # Added 2024-05-03
check_systemd = nagiosPlugins.check_systemd; # Added 2024-05-03
check_zfs = nagiosPlugins.check_zfs; # Added 2024-05-03
check-esxi-hardware = nagiosPlugins.check_esxi_hardware; # Added 2024-05-03
check-mssql-health = nagiosPlugins.check_mssql_health; # Added 2024-05-03
check-nwc-health = nagiosPlugins.check_nwc_health; # Added 2024-05-03
check-openvpn = nagiosPlugins.check_openvpn; # Added 2024-05-03
check-ups-health = nagiosPlugins.check_ups_health; # Added 2024-05-03
check-uptime = nagiosPlugins.check_uptime; # Added 2024-05-03
check-wmiplus = nagiosPlugins.check_wmi_plus; # Added 2024-05-03
checkSSLCert = nagiosPlugins.check_ssl_cert; # Added 2024-05-03
chiaki4deck = chiaki-ng; # Added 2024-08-04
chocolateDoom = chocolate-doom; # Added 2023-05-01
ChowCentaur = chow-centaur; # Added 2024-06-12
Expand Down
2 changes: 1 addition & 1 deletion pkgs/top-level/all-packages.nix
Original file line number Diff line number Diff line change
Expand Up @@ -24811,7 +24811,7 @@ with pkgs;

nagios = callPackage ../servers/monitoring/nagios { };

nagiosPlugins = callPackages ../servers/monitoring/nagios-plugins { };
nagiosPlugins = recurseIntoAttrs (callPackages ../servers/monitoring/nagios-plugins { });

monitoring-plugins = callPackage ../servers/monitoring/plugins { };

Expand Down