From 38e88a91191da92aa69ad0368dc6fc210692687b Mon Sep 17 00:00:00 2001 From: iFargle Date: Tue, 19 Sep 2023 13:49:23 +0900 Subject: [PATCH] Update secrets --- nixos/common/services/promtail.nix | 4 ++-- nixos/common/services/telegraf.nix | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/nixos/common/services/promtail.nix b/nixos/common/services/promtail.nix index 5bffe62c..50828fa6 100644 --- a/nixos/common/services/promtail.nix +++ b/nixos/common/services/promtail.nix @@ -2,7 +2,7 @@ # Promtail Logging # Set up the secret for the password: - sops.secrets.promtail-pass = { + sops.secrets."services/promtail" = { owner = "promtail"; sopsFile = ../../../secrets/secrets.yaml; restartUnits = [ "promtail.service" ]; @@ -29,7 +29,7 @@ url = "https://loki.sysctl.io/loki/api/v1/push"; basic_auth = { username = "loki-sa"; - password_file = config.sops.secrets.promtail-pass.path; + password_file = config.sops.secrets."services/promtail".path; }; }]; scrape_configs = [{ diff --git a/nixos/common/services/telegraf.nix b/nixos/common/services/telegraf.nix index 3e138440..42b67f71 100644 --- a/nixos/common/services/telegraf.nix +++ b/nixos/common/services/telegraf.nix @@ -2,7 +2,7 @@ # Telegraf Monitoring # Set up the secrets file for the token: - sops.secrets.telegraf-token = { + sops.secrets."services/telegraf" = { owner = "telegraf"; sopsFile = ../../../secrets/secrets.yaml; restartUnits = [ "telegraf.service" ]; @@ -28,7 +28,7 @@ # Configure the package: services.telegraf = { enable = true; - environmentFiles = [ /run/secrets/telegraf-token ]; + environmentFiles = [ /run/secrets/services/telegraf ]; extraConfig = { outputs = { influxdb_v2 = {