Docker-Compose | Dockerizing pgAdmin and Postgres - Volumes and Custom Network IP

Welcome to another Docker-Compose tutorial. The Windows platform does support PostgreSQL, but it can be much more convenient to install Postgres and manage PostgreSQL with pgAdmin in containers. In this tutorial we create a docker-compose file to configure Postgres and pgAdmin allowing any other application, in this tutorial Django to connect to it. We go the extra step of configuring the network, assigning static IP addressed to the containers.

Code Repository: (Part 8)

🐱‍🏍Would you like to SUPPORT US FURTHER so that we can make even more great content – Please consider joining our members community.

👍SUBSCRIBE to get more free tutorials, courses and code snippets!


8 thoughts on “Docker-Compose | Dockerizing pgAdmin and Postgres – Volumes and Custom Network IP”
  1. i'm getting this error with pgadmin "Failed to create the directory /var/lib/pgadmin/sessions:

    [Errno 13] Permission denied: '/var/lib/pgadmin/sessions'". Any clue how to slove it?

  2. Thank you very much! You are one of the best Django teachers on the Internet! All tutorials have fantastic qualities! I just finished this Docker series, and it really helps me to dockerize my project and build understanding towards the workflow of using Docker. Thank you for your generous efforts!

  3. What is the best way to configure environment variables for this case? Thanks for the video, this was exactly what I was looking for

  4. Hey, thanks for the awesome tutorial!
    Maybe someone finds this useful: if you have a running postgres application on your machine, trying to run migrations with django might result in a weird error saying that the "test_db" does not exist even though you might have the docker container running and are accessing the db through pgadmin on port 5050.

Leave a Reply

Your email address will not be published.

Captcha loading...