generated from bisco/codex-bootstrap
feat: build headless theatre laboratory website
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
FROM python:3.12.12-slim-bookworm
|
||||
|
||||
ENV PYTHONDONTWRITEBYTECODE=1 \
|
||||
PYTHONUNBUFFERED=1 \
|
||||
PIP_DISABLE_PIP_VERSION_CHECK=1
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
RUN addgroup --system django \
|
||||
&& adduser --system --ingroup django --home /home/django django
|
||||
|
||||
COPY requirements.txt ./
|
||||
RUN pip install --no-cache-dir --requirement requirements.txt
|
||||
|
||||
COPY --chown=django:django . .
|
||||
RUN chmod 755 entrypoint.sh \
|
||||
&& mkdir -p media static \
|
||||
&& chown -R django:django media static
|
||||
|
||||
USER django
|
||||
|
||||
EXPOSE 8000
|
||||
ENTRYPOINT ["./entrypoint.sh"]
|
||||
CMD ["gunicorn", "config.wsgi:application", "--bind", "0.0.0.0:8000", "--workers", "2", "--access-logfile", "-"]
|
||||
Reference in New Issue
Block a user