Files
nixos-servers/system/monitoring/metrics.nix
Torjus Håkestad 1f5b7b13e2
All checks were successful
Run nix flake check / flake-check (push) Successful in 2m11s
monitoring: enable restart-count and ip-accounting collectors
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-06 21:30:47 +01:00

22 lines
400 B
Nix

{ pkgs, ... }:
{
services.prometheus.exporters.node = {
enable = true;
enabledCollectors = [
"systemd"
"logind"
"cgroups"
"processes"
];
};
services.prometheus.exporters.systemd = {
enable = true;
# Default port: 9558
extraFlags = [
"--systemd.collector.enable-restart-count"
"--systemd.collector.enable-ip-accounting"
];
};
}