scripts/build-db.sh
. This builds an image calledauth-db
containing a postgres database calledauth
with userauth
and passwordchangeme
.scripts/build-migrations.sh
. This builds an image calledauth-migrations
which can be run to apply migrations to the database, including the first migration which creates an initial schema. For more details see the README in the migrations folder.scripts/start.sh
. Takes two command line parameters, the version of the image you want to run, and the port you want to expose the database on (the latter defaults to 5432). Starts the database and runs migrations. Requires the images to already exist on your machine.scripts/stop.sh
. Stops a running db image.scripts/build-and-run.sh
. First builds the images and then executesstart.sh
.scripts/clear-docker.sh
. Stops and cleans up any running docker processes.
For persistent data, mount a volume into the database image at /pgdata
.