chore: add gunicorn workers and threads to prevent worker lockup

This commit is contained in:
Dmitry Belan
2026-09-19 15:13:36 +03:00
parent 17cff2608a
commit d1d5cee96f
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -16,4 +16,4 @@ RUN pip install --no-cache-dir -r requirements.txt
COPY . /app/
EXPOSE 8111
CMD ["gunicorn", "--bind", "0.0.0.0:8111", "--chdir", "/app/lmsege", "lmsege.wsgi:application"]
CMD ["gunicorn", "--bind", "0.0.0.0:8111", "--workers", "3", "--threads", "2", "--chdir", "/app/lmsege", "lmsege.wsgi:application"]
+1 -1
View File
@@ -8,7 +8,7 @@ services:
python manage.py makemigrations users lms &&
python manage.py migrate &&
python manage.py collectstatic --noinput &&
gunicorn --bind 0.0.0.0:8111 lmsege.wsgi:application"
gunicorn --bind 0.0.0.0:8111 --workers 3 --threads 2 lmsege.wsgi:application"
volumes:
- .:/app
- db-data:/app/lmsege/db_data