migrate secrets to new structure

This commit is contained in:
TheWanderingCrow 2025-11-02 11:10:45 -05:00
parent 957225dd0d
commit ca8a707ae2
7 changed files with 124 additions and 96 deletions

View file

@ -3,11 +3,13 @@ let
in
{
pkgs,
inputs,
lib,
config,
...
}:
let
sopsFolder = builtins.toString inputs.nix-secrets + "/sops";
frigateConfig = pkgs.writeText "config.yaml" (
lib.generators.toYAML { } {
auth.reset_admin_password = true; # roll the admin password every restart, depend on user accounts for long-lived access
@ -200,7 +202,9 @@ in
FRIGATE_JWT_SECRET=${config.sops.placeholder."frigate/jwt"}
'';
secrets = {
"frigate/jwt" = { };
"frigate/jwt" = {
sopsFile = "${sopsFolder}/services.yaml";
};
};
};
systemd.tmpfiles.rules = [