voidconf/modules/prometheus.nix

25 lines
431 B
Nix
Raw Normal View History

2023-12-30 16:34:24 +01:00
{ lib, config, ... }:
with lib;
2025-04-18 09:37:57 +02:00
let
cfg = config.voidconf.prometheus;
in
{
2024-02-17 18:49:37 +01:00
options.voidconf.prometheus = {
2023-12-30 16:34:24 +01:00
enable = mkEnableOption "Enable prometheus node";
};
config = mkIf cfg.enable {
services.prometheus = {
exporters = {
node = {
enable = true;
2025-04-18 09:37:57 +02:00
enabledCollectors = [
"systemd"
"cpu"
];
2023-12-30 16:34:24 +01:00
port = 9002;
};
};
};
};
}