gunicorn autoreload on source change

Paolo picture Paolo · Oct 8, 2012 · Viewed 51.7k times · Source

Finally I migrated my development env from runserver to gunicorn/nginx.

It'd be convenient to replicate the autoreload feature of runserver to gunicorn, so the server automatically restarts when source changes. Otherwise I have to restart the server manually with kill -HUP.

Any way to avoid the manual restart?

Answer

Dmitry  Ziolkovskiy picture Dmitry Ziolkovskiy · Jul 22, 2014

While this is old question you need to know that ever since version 19.0 gunicorn has had the --reload option. So now no third party tools are needed.