- docker >= 17.12.0+
- docker-compose
- Clone or download this repository
- Go inside of directory,
cd compose-postgres
- Run this command
docker-compose up -d
Install direnv to set up personalize workspace environment variables.
- Run
cp .envrc_vars.example .envrc_vars
- Set your own variable values
- Run
direnv allow
Expected output
$ direnv allow
direnv: loading .envrc
direnv: export +PGADMIN_DEFAULT_EMAIL +PGADMIN_DEFAULT_PASSWORD +POSTGRES_PASSWORD +POSTGRES_USER
Each time you modify .envrc_vars run direnv reload
This Compose file contains the following environment variables:
POSTGRES_USER
the default value is postgresPOSTGRES_PASSWORD
the default value is changemePGADMIN_PORT
the default value is 5050PGADMIN_DEFAULT_EMAIL
the default value is [email protected]PGADMIN_DEFAULT_PASSWORD
the default value is admin
localhost:5432
- Username: postgres (as a default)
- Password: changeme (as a default)
- URL:
http://localhost:5050
- Username: [email protected] (as a default)
- Password: admin (as a default)
- Host name/address
postgres
- Port
5432
- Username as
POSTGRES_USER
, by default:postgres
- Password as
POSTGRES_PASSWORD
, by defaultchangeme