tsuki: move gitea postgres password to sops

This commit is contained in:
2023-03-08 15:59:50 +01:00
parent a82a3f95c0
commit 5e2a5a939b
2 changed files with 11 additions and 3 deletions

View File

@@ -13,6 +13,12 @@
packages = with unstable-pkgs; [ gitea ];
};
sops.secrets."postgres/gitea" = rec {
restartUnits = [ "gitea.service" ];
owner = config.services.gitea.user;
group = config.users.users.${owner}.group;
};
services.gitea = {
enable = true;
user = "git";
@@ -32,7 +38,7 @@
database = {
type = "postgres";
user = "gitea";
passwordFile = secrets.keys.postgres.gitea;
passwordFile = config.sops.secrets."postgres/gitea".path;
createDatabase = false;
};