Skip to content

Instantly share code, notes, and snippets.

@tsirolnik
tsirolnik / compose_postgresql_pgadmin.md
Last active July 21, 2018 10:38
Connecting Docker Compose PostgreSQL Container to PgAdmin
  • Run your compose with docker compose up
  • Get the name of your compose network with docker network ls
    • The network name will be in the format of <project>_default unless changed
  • Run the pgadmin command
    • docker run --net <compose_network> -v pgadmin4:/home/pgadmin/.pgadmin -p 5050:5050 --link <pg_container_name>:<pg_container_name> --rm meedan/pgadmin
  • Browse to http://localhost:5050/
  • Login with - admin@pgadmin.org:pgadmin

This is based on the following sources -