Skip to content

Docker helps us package container based applications like python, django, flask, nginx, gunicorn, PostgreSQL, MySQL as a deployment ready system. We will, in this article, deploy a django app with nginx, gunicorn, PostgreSQL in their separate docker. We will package the whole project with docker-compose.

by-sabbir/django-gunicorn-nginx-docker

Repository files navigation

Dockerize Django along with Nginx and PostgreSQL

Docker will make your life a bit easier when it comes to deployment and CI/CD. This method can be used to deploy most stacks with Nginx and Postgres, ie. Flask, django-rest, FastAPI, NodeJS...

Installation

Your system must have docker-compose to follow along.

docker-compose build
docker-compose up

You would be able to access

localhost:8008

Usage

stop the container

docker-compose down

drop to django shell

docker-compose exec web python manage.py shell

more at here

Contributing

You can do whatever you want with this repo.

About

Docker helps us package container based applications like python, django, flask, nginx, gunicorn, PostgreSQL, MySQL as a deployment ready system. We will, in this article, deploy a django app with nginx, gunicorn, PostgreSQL in their separate docker. We will package the whole project with docker-compose.

Topics

Resources

Stars

Watchers

Forks