From 77845a9ba9d2550827ef6484154ec92de9dc5463 Mon Sep 17 00:00:00 2001 From: Adithya Nair Date: Sat, 20 Jul 2024 23:16:14 +0530 Subject: [PATCH] wynne: create databases for dendrite --- hosts/wynne/services/apps/postgresql.nix | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/hosts/wynne/services/apps/postgresql.nix b/hosts/wynne/services/apps/postgresql.nix index b9023a8..6277e84 100644 --- a/hosts/wynne/services/apps/postgresql.nix +++ b/hosts/wynne/services/apps/postgresql.nix @@ -16,8 +16,13 @@ host all all 10.10.10.0/24 trust host all all fd7c:585c:c4ae::0/64 trust ''; - ensureDatabases = [ ]; - ensureUsers = [ ]; + ensureDatabases = [ "dendrite" ]; + ensureUsers = [ + { + name = "dendrite"; + ensureDBOwnership = true; + } + ]; }; }; systemd.services.postgresql.unitConfig.RequiresMountsFor = [ "/mnt/data" ];