Created
July 2, 2024 15:06
-
-
Save sandromello/8645c72ea4fd229571868bc3405131ac to your computer and use it in GitHub Desktop.
run postgres
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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