Skip to content

Dockerizing Django and Postgres with Conda for dev ( with pgAdmin ) and prod ( with gunicorn and nginx )

License

Notifications You must be signed in to change notification settings

adiian/docker-django-conda-nginx

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Dockerizing Django and Postgres

  • Using Conda as package manager
  • Using Docker Composer

Development

  • Django using embeded server
  • Postgres
  • pgAdmin

Production

  • Nginx as web server, reverse proxi, serving static content
  • Django container with gunicorn as the app wsgi server
  • Postgres

Customization

App files

The path to django app files is ./mysite

Database

The initial postgres sql dump should be created using the follosing command and copied in postgres folder(mysite is the name of the db):

pg_dump    -h localhost -p 5432 -U postgres -W -d mysite > site.sql

In case a manually restore is needed:

pg_restore -h localhost -p 5432 -U postgres -d mysite psql_dump.sql

TODOs:

  • generating letsencrypt certificates
  • using network bridges
  • maybe app folder(mysite) should be kept outside of the current path, in case it will has a separate repository than docker files

About

Dockerizing Django and Postgres with Conda for dev ( with pgAdmin ) and prod ( with gunicorn and nginx )

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published