From 9ec982155677076419a5cb3d396f69170eb42b07 Mon Sep 17 00:00:00 2001 From: catvayor Date: Fri, 19 Apr 2024 23:30:26 +0200 Subject: [PATCH] feat(ups): nut_exporter and scraping --- machines/storage01/prometheus.nix | 4 ++++ machines/vault01/ups.nix | 5 +++++ 2 files changed, 9 insertions(+) diff --git a/machines/storage01/prometheus.nix b/machines/storage01/prometheus.nix index 0e07478..b2b3af6 100644 --- a/machines/storage01/prometheus.nix +++ b/machines/storage01/prometheus.nix @@ -64,6 +64,10 @@ in password_file = config.age.secrets."prometheus-uptime-kuma-apikey".path; }; } + { + job_name = "hyp01_ups"; + static_configs = [ { targets = [ "100.80.255.180:9199" ]; } ]; + } ]; }; diff --git a/machines/vault01/ups.nix b/machines/vault01/ups.nix index 69934fd..71a53f5 100644 --- a/machines/vault01/ups.nix +++ b/machines/vault01/ups.nix @@ -18,4 +18,9 @@ # user = "eatonMon"; # }; }; + services.prometheus.exporters.nut = { + enable = true; + listenAddress = "100.80.255.180"; + port = 9199; + }; }