buildbot-nix/nix/prometheus-plugin.nix
raito 3876a30117 feat: support Prometheus exports
We package a quite old plugin for Buildbot: https://github.com/claws/buildbot-prometheus
Ideally, we should probably vendor it and maintain it ourselves.

There seems to be no protection against the metrics endpoint for
Buildbot, this is not a big deal given that the CI is public.

Signed-off-by: Raito Bezarius <raito@lix.systems>
2024-05-06 14:26:32 +02:00

43 lines
815 B
Nix

{ lib
, buildPythonPackage
, fetchFromGitHub
, setuptools
, wheel
, buildbot
, prometheus-client
, twisted
}:
buildPythonPackage rec {
pname = "buildbot-prometheus";
version = "unstable-2024-05-06";
pyproject = true;
src = fetchFromGitHub {
owner = "claws";
repo = "buildbot-prometheus";
rev = "0c81a89bbe34628362652fbea416610e215b5d1e";
hash = "sha256-bz2Nv2RZ44i1VoPvQ/XjGMfTT6TmW6jhEVwItPk23SM=";
};
nativeBuildInputs = [
setuptools
wheel
];
propagatedBuildInputs = [
buildbot
prometheus-client
twisted
];
pythonImportsCheck = [ "buildbot_prometheus" ];
meta = with lib; {
description = "";
homepage = "https://github.com/claws/buildbot-prometheus";
license = licenses.mit;
maintainers = with maintainers; [ raitobezarius ];
};
}