Skip to content

davecremins/dockerizing-django

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

80 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Comms Between Different Containers

Forked From -> https://realpython.com/blog/python/django-development-with-docker-compose-and-machine/

Featuring:

  • Nginx: Forwards requests to Django and Node
  • Django: Serves the web interface component
  • Postgres: Persistence layer to store all the data
  • Redis: Message broker between Django and Node using Pub/Sub pattern
  • Node: Express server for socket comms and subscriber to Redis Pub/Sub

Instructions

  1. Build images - docker-compose build
  2. Start service containers - docker-compose up
  3. Create django migrations - docker-compose run web /usr/local/bin/python manage.py migrate
  4. Browse to http://localhost and send a message
  5. Verify that the node container prints the message received from the redis broker
  6. Remove containers - docker-compose down

Releases

No releases published

Packages

 
 
 

Contributors

Languages

  • JavaScript 39.0%
  • Python 34.0%
  • HTML 25.6%
  • Other 1.4%