diff --git a/hosts/aws/tyo0/services/prometheus.nix b/hosts/aws/tyo0/services/prometheus.nix index 6f3a3bd..3218634 100644 --- a/hosts/aws/tyo0/services/prometheus.nix +++ b/hosts/aws/tyo0/services/prometheus.nix @@ -7,7 +7,7 @@ }: let inherit (config.lib) ports; - targets = lib.mapAttrsToList (_name: node: node.fqdn) nodes; + targets = lib.mapAttrsToList (_name: node: node.fqdn) nodes ++ [ "pek0.ny4.dev" ]; in { services.prometheus = { @@ -36,12 +36,7 @@ in username = "prometheus"; password_file = config.sops.secrets."prometheus/auth".path; }; - static_configs = lib.singleton { - targets = [ - "pek0.ny4.dev" - "tyo0.ny4.dev" - ] ++ targets; - }; + static_configs = lib.singleton { inherit targets; }; } { job_name = "caddy"; @@ -50,12 +45,7 @@ in username = "prometheus"; password_file = config.sops.secrets."prometheus/auth".path; }; - static_configs = lib.singleton { - targets = [ - "tyo0.ny4.dev" - "pek0.ny4.dev" - ] ++ targets; - }; + static_configs = lib.singleton { inherit targets; }; } { job_name = "blackbox_exporter"; diff --git a/hosts/dust/default.nix b/hosts/dust/default.nix index 69de060..a79014a 100644 --- a/hosts/dust/default.nix +++ b/hosts/dust/default.nix @@ -10,7 +10,6 @@ [ ../../nixos/profiles/restic ../../nixos/profiles/sing-box - ../../nixos/profiles/wireless ./anti-feature.nix ./disko.nix diff --git a/nixos/profiles/restic/default.nix b/nixos/profiles/restic/default.nix index e34e82e..aab59af 100644 --- a/nixos/profiles/restic/default.nix +++ b/nixos/profiles/restic/default.nix @@ -1,6 +1,6 @@ -{ config, ... }: +{ lib, config, ... }: { - sops.secrets = builtins.mapAttrs (_n: v: v // { sopsFile = ./secrets.yaml; }) { + sops.secrets = lib.mapAttrs (_n: v: v // { sopsFile = ./secrets.yaml; }) { "restic/environment" = { }; "restic/password" = { }; "restic/repository" = { };