about summary refs log tree commit diff
path: root/smoke-test.nix
diff options
context:
space:
mode:
Diffstat (limited to 'smoke-test.nix')
-rw-r--r--smoke-test.nix13
1 files changed, 13 insertions, 0 deletions
diff --git a/smoke-test.nix b/smoke-test.nix
index 139117f..b043a31 100644
--- a/smoke-test.nix
+++ b/smoke-test.nix
@@ -6,6 +6,19 @@ kittybox:
     kittybox = { config, pkgs, lib, ... }: {
       imports = [ kittybox.nixosModules.default ];
 
+      services.postgresql = {
+        enable = true;
+        ensureDatabases = ["kittybox"];
+        ensureUsers = [ {
+          name = "kittybox";
+          ensurePermissions = {
+            "DATABASE kittybox" = "ALL PRIVILEGES";
+          };
+        } ];
+      };
+
+      systemd.services.kittybox.wants = [ "postgresql.service" ];
+      systemd.services.kittybox.after = [ "postgresql.service" ];
       systemd.services.kittybox.wantedBy = lib.mkForce [];
 
       services.kittybox = {