diff options
Diffstat (limited to 'modules/services/monitoring/node-exporter.nix')
-rw-r--r-- | modules/services/monitoring/node-exporter.nix | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/modules/services/monitoring/node-exporter.nix b/modules/services/monitoring/node-exporter.nix new file mode 100644 index 0000000..a205bba --- /dev/null +++ b/modules/services/monitoring/node-exporter.nix @@ -0,0 +1,19 @@ +{ config, pkgs, lib, ... }: +let cfg = config.my.services.monitoring.node-exporter; +in +{ + options.my.services.monitoring.node-exporter = with lib; { + enable = mkEnableOption "Prometheus metrics exporter"; + }; + + config = lib.mkIf cfg.enable { + services.prometheus = { + exporters = { + node = { + enable = true; + enabledCollectors = [ "tcpstat" "systemd" "interrupts" ]; + }; + }; + }; + }; +} |