3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/pkgs/servers/monitoring/plugins/esxi.nix

37 lines
858 B
Nix
Raw Normal View History

{ stdenv, fetchFromGitHub, python3Packages }:
2017-08-07 16:24:07 +01:00
let
bName = "check_esxi_hardware";
in python3Packages.buildPythonApplication rec {
pname = stdenv.lib.replaceStrings [ "_" ] [ "-" ] bName;
version = "20200710";
2017-08-07 16:24:07 +01:00
src = fetchFromGitHub {
owner = "Napsty";
repo = bName;
rev = version;
sha256 = "EC6np/01S+5SA2H9z5psJ9Pq/YoEyGdHL9wHUKKsNas=";
2017-08-07 16:24:07 +01:00
};
dontBuild = true;
doCheck = false;
installPhase = ''
runHook preInstall
install -Dm755 ${bName}.py $out/bin/${bName}
install -Dm644 -t $out/share/doc/${pname} README.md
2017-08-07 16:24:07 +01:00
runHook postInstall
'';
propagatedBuildInputs = with python3Packages; [ pywbem requests setuptools ];
2017-08-07 16:24:07 +01:00
meta = with stdenv.lib; {
homepage = "https://www.claudiokuenzler.com/nagios-plugins/";
2017-08-07 16:24:07 +01:00
license = licenses.gpl2;
maintainers = with maintainers; [ peterhoeg ];
2017-08-07 16:24:07 +01:00
};
}