Skip to content

Commit 3c302d7

Browse files
committed
Raise and make configurable UWSGI http timeout and max requests
1 parent 9c5d3c5 commit 3c302d7

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

bin/docker_start.sh

+5-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,9 @@ ${SCRIPTPATH}/wait_for_db.sh
1414

1515
uwsgi_port=${UWSGI_PORT:-8000}
1616
uwsgi_processes=${UWSGI_PROCESSES:-4}
17-
uwsgi_threads=${UWSGI_THREADS:-1}
17+
uwsgi_threads=${UWSGI_THREADS:-8}
18+
uwsgi_http_timeout=${UWSGI_HTTP_TIMEOUT:-120}
19+
uwsgi_max_requests=${UWSGI_MAX_REQUESTS:-100}
1820

1921
# Apply database migrations
2022
>&2 echo "Apply database migrations"
@@ -25,6 +27,8 @@ python src/manage.py migrate
2527
exec uwsgi \
2628
--http :$uwsgi_port \
2729
--http-keepalive \
30+
--max-requests $uwsgi_max_requests \
31+
--http-timeout $uwsgi_http_timeout \
2832
--module open_inwoner.wsgi \
2933
--static-map /static=/app/static \
3034
--static-map /media=/app/media \

0 commit comments

Comments
 (0)