PostgreSQL is open-source relational database.
To start the Postgres container, run
docker compose up --detach
Once the container is running, you can access the database using the psql
command-line tool.
PGPASSWORD=postgres psql -h localhost -U postgres -d mydatabase
To stop and remove the containers, run
docker compose down --volumes