Instead of starting the PostgreSQL server and the Node.js server in the same container, docker-compose.yml defines both as separate containers.
This should improve the ability to use standard docker tooling and container management, and hopefully also avoid issues with the system not starting up properly.
The PR also adds code to wait for Postgres to come up properly, and retry connecting to it.
With Docker, this should be usable with:
docker compose -f ./docker-compose.yml up
For Podman users, podman-compose is needed:
pip3 install podman-compose # if not already available
podman-compose up
The GitLab CI setup for benchmarking is not using podman-compose, and instead manually starts both containers. Unfortunately, podman-compose is not as full feature as needed. It doesn't fully support its --abort-on-container-exit/--exit-code-from, and dealing with environment variables is problematic, too.
This PR changes how the docker-based setup works.
Instead of starting the PostgreSQL server and the Node.js server in the same container, docker-compose.yml defines both as separate containers.
This should improve the ability to use standard docker tooling and container management, and hopefully also avoid issues with the system not starting up properly.
The PR also adds code to wait for Postgres to come up properly, and retry connecting to it.
With Docker, this should be usable with:
For Podman users, podman-compose is needed:
The GitLab CI setup for benchmarking is not using podman-compose, and instead manually starts both containers. Unfortunately, podman-compose is not as full feature as needed. It doesn't fully support its
--abort-on-container-exit
/--exit-code-from
, and dealing with environment variables is problematic, too.