Skip to content

Instantly share code, notes, and snippets.

@sandromello
Created July 2, 2024 15:06
Show Gist options
  • Save sandromello/8645c72ea4fd229571868bc3405131ac to your computer and use it in GitHub Desktop.
Save sandromello/8645c72ea4fd229571868bc3405131ac to your computer and use it in GitHub Desktop.
run postgres
mkdir -p /opt/hoop/pgdata
PGUSER=hoopdevuser
PGDATABASE=hoopdevdemo
PGPASSWORD="1a2b3c4d"
docker run -p 5432:5432 -d --rm --name hoopdevpg \
-e POSTGRES_USER=$PGUSER \
-e POSTGRES_DB=$PGDATABASE \
-e POSTGRES_PASSWORD=$PGPASSWORD \
-e PGUSER=$PGUSER \
-e PGDATABASE=$PGDATABASE \
-e PGPASSWORD=$PGPASSWORD \
-e PG_DATA=/var/lib/postgresql/data/pgdata \
-v /opt/hoop/pgdata/:/var/lib/postgresql/data/ \
postgres:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment