more db ip fix test

This commit is contained in:
soraefir
2026-05-06 03:22:55 +02:00
parent e276df28b4
commit f80ba36c2a
2 changed files with 12 additions and 9 deletions

View File

@@ -14,14 +14,17 @@ in {
services.postgresql = {
enable = true;
enableTCPIP = true; # Required to listen on network interfaces
authentication = pkgs.lib.mkOverride 10 ''
# TYPE DATABASE USER ADDRESS METHOD
local all all trust
host all all 127.0.0.1/32 trust
host all all 10.0.0.0/8 scram-sha-256
host all all 169.254.0.0/16 scram-sha-256
host all all ::1/128 trust
'';
settings = {
listen_addresses = lib.mkForce "*";
};
# authentication = pkgs.lib.mkOverride 10 ''
# # TYPE DATABASE USER ADDRESS METHOD
# local all all trust
# host all all 127.0.0.1/32 trust
# host all all 10.0.0.0/8 scram-sha-256
# host all all 169.254.0.0/16 scram-sha-256
# host all all ::1/128 trust
# '';
ensureDatabases = map (name: "${name}_db") allApps;
ensureUsers = map (name: { name = "${name}_user"; }) allApps;
};