blob: d51d9bd3f79cce0a9700028c594d492a52990a6f (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
|
{ lib
, python3
, fetchPypi
, nixosTests
}:
python3.pkgs.buildPythonApplication rec {
pname = "knot-exporter";
version = "3.3.4";
pyproject = true;
src = fetchPypi {
pname = "knot_exporter";
inherit version;
hash = "sha256-jZNNJiJxq3pNSZFwu2UEHhrA0odIDY0UO+d4PJII1ZI=";
};
nativeBuildInputs = [
python3.pkgs.hatchling
];
propagatedBuildInputs = with python3.pkgs; [
libknot
prometheus-client
psutil
];
pythonImportsCheck = [
"knot_exporter"
];
passthru.tests = { inherit (nixosTests.prometheus-exporters) knot; };
meta = with lib; {
description = "Prometheus exporter for Knot DNS";
homepage = "https://gitlab.nic.cz/knot/knot-dns/-/tree/master/python/knot_exporter";
license = licenses.gpl3Only;
maintainers = with maintainers; [ ma27 hexa ];
mainProgram = "knot-exporter";
};
}
|