diff --git a/master.nix b/master.nix index ba48972..3b66b8d 100644 --- a/master.nix +++ b/master.nix @@ -23,6 +23,7 @@ in ./tailscale.nix ./incus.nix ./drives.nix + ./prometheus.nix #./auto-upgrade.nix ]; diff --git a/prometheus.nix b/prometheus.nix new file mode 100644 index 0000000..0dd619f --- /dev/null +++ b/prometheus.nix @@ -0,0 +1,12 @@ +{ config, pkgs, ... }: + +{ + networking.firewall.allowedTCPPorts = [ 9100 ]; + services.prometheus.exporters.node = { + enable = true; + port = 9100; + enabledCollectors = [ "systemd" ]; + extraFlags = [ "--collector.ethtool" "--collector.softirqs" "--collector.tcpstat" "--collector.wifi" ]; + }; +} +