2019-09-05 07:46:39 +01:00
|
|
|
{ stdenv, buildGoPackage, fetchFromGitHub }:
|
|
|
|
|
|
|
|
buildGoPackage rec {
|
|
|
|
pname = "process-exporter";
|
2020-11-04 10:30:18 +00:00
|
|
|
version = "0.7.1";
|
2019-09-05 07:46:39 +01:00
|
|
|
|
|
|
|
goPackagePath = "github.com/ncabatoff/process-exporter";
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "ncabatoff";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2020-11-04 10:30:18 +00:00
|
|
|
sha256 = "0jkh4xzjlrlabpll3igpyhqs35f1dxifjkbfxvijjcq9yahxfj0x";
|
2019-09-05 07:46:39 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
postPatch = ''
|
|
|
|
substituteInPlace proc/read_test.go --replace /bin/cat cat
|
|
|
|
'';
|
|
|
|
|
|
|
|
doCheck = true;
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
|
|
|
description = "Prometheus exporter that mines /proc to report on selected processes";
|
|
|
|
homepage = "https://github.com/ncabatoff/process-exporter";
|
|
|
|
license = licenses.mit;
|
2020-07-29 11:57:20 +01:00
|
|
|
maintainers = with maintainers; [ _1000101 ];
|
2019-09-05 07:46:39 +01:00
|
|
|
platforms = platforms.linux;
|
|
|
|
};
|
|
|
|
}
|