9 stdenvNoCC.mkDerivation rec {
10 pname = "prometheus-restic-exporter";
13 src = fetchFromGitHub {
15 repo = "restic-exporter";
17 hash = "sha256-gXiEts0EY9H01+rs+2o+cbVENotM33uhcQiGDtroSU4=";
21 (python3.withPackages (ps: [ ps.prometheus-client ]))
27 install -D -m0755 restic-exporter.py $out/bin/restic-exporter.py
29 substituteInPlace $out/bin/restic-exporter.py --replace-fail \"restic\" \"${lib.makeBinPath [ restic ]}/restic\"
31 patchShebangs $out/bin/restic-exporter.py
37 restic-exporter = nixosTests.prometheus-exporters.restic;
41 description = "Prometheus exporter for the Restic backup system";
42 homepage = "https://github.com/ngosang/restic-exporter";
43 changelog = "https://github.com/ngosang/restic-exporter/blob/${src.rev}/CHANGELOG.md";
44 license = licenses.mit;
45 maintainers = with maintainers; [ minersebas ];
46 mainProgram = "restic-exporter.py";
47 platforms = platforms.all;