diff --git a/.prod/uwsgi_configuration.ini b/.prod/uwsgi_configuration.ini index 9f7726391..8742aa481 100644 --- a/.prod/uwsgi_configuration.ini +++ b/.prod/uwsgi_configuration.ini @@ -9,9 +9,8 @@ static-map = /media=$(MEDIA_ROOT) end-if = uid = nobody gid = nogroup +enable-threads = true master = 1 -processes = 2 -threads = 2 socket-timeout = 60 # Reload workers regularly to keep memory fresh diff --git a/docker/django/docker-entrypoint.sh b/docker/django/docker-entrypoint.sh index 892d218c4..576462bc8 100755 --- a/docker/django/docker-entrypoint.sh +++ b/docker/django/docker-entrypoint.sh @@ -28,7 +28,10 @@ fi if [[ -n "$@" ]]; then "$@" elif [[ "$DEV_SERVER" = "true" ]]; then - python ./manage.py runserver_plus 0.0.0.0:8000 + python -Wd ./manage.py runserver_plus 0.0.0.0:8000 else - uwsgi --ini .prod/uwsgi_configuration.ini + uwsgi \ + --ini .prod/uwsgi_configuration.ini \ + --processes ${UWSGI_PROCESSES-2} \ + --threads ${UWSGI_THREADS-2} fi