about summary refs log tree commit diff
path: root/ops/modules
diff options
context:
space:
mode:
authorVincent Ambo <mail@tazj.in>2021-12-10T06·58+0300
committerVincent Ambo <mail@tazj.in>2021-12-10T07·32+0300
commit78744c00f5df97d45b2c1b865cf8756edec0c5a3 (patch)
tree791368a0cdd21400dbda9f202be21a697dfb1afe /ops/modules
parent496d8994287f27f93f08ac847e430a6f2dfc94bd (diff)
refactor(ops): Move clbot secret into agenix r/3174
Relates to b/161

Change-Id: I7badf22ff93bb4e8b06e4dd4a8bf880b0bd48f09
Diffstat (limited to 'ops/modules')
-rw-r--r--ops/modules/clbot.nix8
1 files changed, 7 insertions, 1 deletions
diff --git a/ops/modules/clbot.nix b/ops/modules/clbot.nix
index 71ff2fbc3288..ef4c2ab23795 100644
--- a/ops/modules/clbot.nix
+++ b/ops/modules/clbot.nix
@@ -37,7 +37,7 @@ let
 
       serviceConfig = {
         User = "clbot";
-        EnvironmentFile = "/etc/secrets/clbot";
+        EnvironmentFile = cfg.secretsFile;
         Restart = "always";
       };
     };
@@ -55,6 +55,12 @@ in {
       type = with types; listOf str;
       description = "Channels in which to post (generates one unit per channel)";
     };
+
+    secretsFile = mkOption {
+      type = types.str;
+      description = "EnvironmentFile from which to load secrets";
+      default = "/run/agenix/clbot";
+    };
   };
 
   config = mkIf cfg.enable {