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