mirror of
https://github.com/juspay/services-flake.git
synced 2024-09-20 00:39:49 +03:00
13 lines
345 B
Nix
13 lines
345 B
Nix
|
{ config, ... }: {
|
||
|
services.postgres = {
|
||
|
enable = true;
|
||
|
listen_addresses = "127.0.0.1";
|
||
|
};
|
||
|
testScript = ''
|
||
|
process_compose.wait_until(lambda procs:
|
||
|
procs["postgres"]["status"] == "Running"
|
||
|
)
|
||
|
machine.succeed("echo 'SELECT version();' | ${config.services.postgres.package}/bin/psql -h 127.0.0.1 -U tester")
|
||
|
'';
|
||
|
}
|