Skip to content

Commit a051429

Browse files
committed
[PPHA-182] Use gunicorn in prod and dev server locally
1 parent f740a81 commit a051429

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

Dockerfile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ COPY lung_cancer_screening ./lung_cancer_screening
77
RUN npm ci
88
RUN npm run compile
99

10+
1011
FROM python:3.12-alpine3.19 AS builder
1112

1213
ENV PYTHONDONTWRITEBYTECODE=1 \
@@ -55,4 +56,4 @@ USER app
5556

5657
EXPOSE 8000
5758

58-
CMD ["python", "manage.py", "runserver", "0.0.0.0:8000"]
59+
CMD ["/app/.venv/bin/gunicorn", "--bind", "0.0.0.0:8000", "lung_cancer_screening.wsgi"]

docker-compose.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
services:
44
web:
55
build: .
6+
command: python manage.py runserver 0.0.0.0:8000
67
ports:
78
- "8000:8000"
89
env_file:

0 commit comments

Comments
 (0)