
Show HN: Production-ready Django on Docker - morninj
https://github.com/morninj/django-docker
======
brianwawok
So I really want to believe in docker. In general I think the idea of
containers are awesome, and they can be awesome in a lot of ways. Have seen
them do awesome things for some complex setups.

I honestly do not see what you are getting here though other than just saying
"I used docker". Let's compare this to a simple alternative that I used
learning DJango:

1) Local - Dev server with virtualenv

2) Prod - Set of ansible scripts applied on top of a default AMI or image from
a cloud provider. This adds nginx and gnuicorn and all the stuff you would
expect. Runs the same virtualenv stuff used above.

The dev experience seems better in my way, as dev server handles reloads
easier.

My prod experience should have some tiny perf boost (as it's just in a VPC
container vs a container in a container). Deployments should be faster as it
is just a git pull and a gnuicorn bounce. What do I give up?

An example of the prod ansible stack would be
[https://github.com/jcalazan/ansible-django-
stack](https://github.com/jcalazan/ansible-django-stack) , but there are
others (or you can write your own).

------
cjbprime
Huh. Why do you think putting a bunch of services all inside a single Docker
container is a good idea for production?

~~~
morninj
How would you recommend separating them? In the deployment instructions, I
recommend using a separate database server, so this container is mainly
running Nginx+Gunicorn+Django in production. The local MySQL server is only
there for dev convenience.

