fix postgres module tests
This commit is contained in:
parent
845017103f
commit
aa3448cb1f
1 changed files with 14 additions and 0 deletions
|
@ -22,6 +22,12 @@ let
|
||||||
in {
|
in {
|
||||||
inherit (cfg) systemd services;
|
inherit (cfg) systemd services;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
commonSettings = {
|
||||||
|
idle_in_transaction_session_timeout = "30s";
|
||||||
|
idle_session_timeout = "30s";
|
||||||
|
track_io_timing = "true";
|
||||||
|
};
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
testPostgresNoOptions = {
|
testPostgresNoOptions = {
|
||||||
|
@ -30,6 +36,7 @@ in
|
||||||
enable = false;
|
enable = false;
|
||||||
ensureUsers = [];
|
ensureUsers = [];
|
||||||
ensureDatabases = [];
|
ensureDatabases = [];
|
||||||
|
settings = commonSettings;
|
||||||
};
|
};
|
||||||
systemd.services.postgresql.postStart = "";
|
systemd.services.postgresql.postStart = "";
|
||||||
};
|
};
|
||||||
|
@ -42,6 +49,7 @@ in
|
||||||
enable = true;
|
enable = true;
|
||||||
ensureUsers = [];
|
ensureUsers = [];
|
||||||
ensureDatabases = [];
|
ensureDatabases = [];
|
||||||
|
settings = commonSettings;
|
||||||
};
|
};
|
||||||
systemd.services.postgresql.postStart = "";
|
systemd.services.postgresql.postStart = "";
|
||||||
};
|
};
|
||||||
|
@ -64,6 +72,7 @@ in
|
||||||
};
|
};
|
||||||
}];
|
}];
|
||||||
ensureDatabases = ["mydatabase"];
|
ensureDatabases = ["mydatabase"];
|
||||||
|
settings = commonSettings;
|
||||||
};
|
};
|
||||||
systemd.services.postgresql.postStart = "";
|
systemd.services.postgresql.postStart = "";
|
||||||
};
|
};
|
||||||
|
@ -91,6 +100,7 @@ in
|
||||||
};
|
};
|
||||||
}];
|
}];
|
||||||
ensureDatabases = ["mydatabase"];
|
ensureDatabases = ["mydatabase"];
|
||||||
|
settings = commonSettings;
|
||||||
};
|
};
|
||||||
systemd.services.postgresql.postStart = ''
|
systemd.services.postgresql.postStart = ''
|
||||||
$PSQL -tA <<'EOF'
|
$PSQL -tA <<'EOF'
|
||||||
|
@ -139,6 +149,7 @@ in
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
ensureDatabases = ["db1" "db2"];
|
ensureDatabases = ["db1" "db2"];
|
||||||
|
settings = commonSettings;
|
||||||
};
|
};
|
||||||
systemd.services.postgresql.postStart = "";
|
systemd.services.postgresql.postStart = "";
|
||||||
};
|
};
|
||||||
|
@ -181,6 +192,7 @@ in
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
ensureDatabases = ["db1" "db2"];
|
ensureDatabases = ["db1" "db2"];
|
||||||
|
settings = commonSettings;
|
||||||
};
|
};
|
||||||
systemd.services.postgresql.postStart = ''
|
systemd.services.postgresql.postStart = ''
|
||||||
$PSQL -tA <<'EOF'
|
$PSQL -tA <<'EOF'
|
||||||
|
@ -236,6 +248,7 @@ in
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
ensureDatabases = ["db1" "db2"];
|
ensureDatabases = ["db1" "db2"];
|
||||||
|
settings = commonSettings;
|
||||||
};
|
};
|
||||||
systemd.services.postgresql.postStart = ''
|
systemd.services.postgresql.postStart = ''
|
||||||
$PSQL -tA <<'EOF'
|
$PSQL -tA <<'EOF'
|
||||||
|
@ -269,6 +282,7 @@ in
|
||||||
enable = false;
|
enable = false;
|
||||||
ensureUsers = [];
|
ensureUsers = [];
|
||||||
ensureDatabases = [];
|
ensureDatabases = [];
|
||||||
|
settings = commonSettings;
|
||||||
|
|
||||||
enableTCPIP = true;
|
enableTCPIP = true;
|
||||||
authentication = ''
|
authentication = ''
|
||||||
|
|
Loading…
Reference in a new issue