11 lines
495 B
Docker
Executable File
11 lines
495 B
Docker
Executable File
FROM python:3.12-slim
|
|
ENV PYTHONDONTWRITEBYTECODE=1 PYTHONUNBUFFERED=1
|
|
WORKDIR /app
|
|
COPY requirements.txt ./
|
|
RUN pip install --no-cache-dir -r requirements.txt && useradd --create-home --uid 10001 membership
|
|
COPY --chown=membership:membership . ./
|
|
USER membership
|
|
EXPOSE 8000
|
|
# Access logs omit query strings and verification tokens; the edge must too.
|
|
CMD ["gunicorn", "config.wsgi:application", "--bind", "0.0.0.0:8000", "--workers", "2", "--timeout", "120", "--error-logfile", "-"]
|