Skip to content

Commit

Permalink
Add multiple workers to gunicorn
Browse files Browse the repository at this point in the history
  • Loading branch information
Sispheor committed Nov 20, 2024
1 parent 306ef43 commit e0906e9
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion docker/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,4 @@ echo "Inserting default data"
python manage.py insert_default_data

echo "Starting web server"
gunicorn --bind 0.0.0.0:8000 --pythonpath /app/squest Squest.wsgi
gunicorn --bind 0.0.0.0:8000 --workers ${GUNICORN_WORKERS:-4} --pythonpath /app/squest Squest.wsgi
2 changes: 2 additions & 0 deletions docker/environment_variables/squest.env
Original file line number Diff line number Diff line change
Expand Up @@ -33,3 +33,5 @@ REDIS_CACHE_HOST=redis-cache

WAIT_HOSTS=db:3306,rabbitmq:5672
WAIT_TIMEOUT=60

GUNICORN_WORKERS=4

0 comments on commit e0906e9

Please sign in to comment.