Skip to content

build: Add docker-compose support for setting up the database

Philip Withnall requested to merge pwithnall/odrs-web:podman-compose into master

Add a docker-compose.yml file which allows the flask container to be built at the same time as a database container, and the whole lot to be run together.

This makes testing ODRS significantly simpler, and significantly simpler to document. It requires docker-compose (or podman-compose).

It reworks the Dockerfile to just contain the flask app, rather than also containing a HTTPD server and running the commands to set up the database. I believe it’s generally accepted best practice to separate DB initialisation from image building, not least because you need to have the DB container around and running while building the app container in order to do that, and podman doesn’t support that.

Signed-off-by: Philip Withnall withnall@endlessm.com

Merge request reports