alternative-backend-service/dockerfile

21 lines
441 B
Plaintext
Raw Normal View History

FROM python:3.12-slim
2025-11-22 19:13:34 +00:00
ENV PYTHONDONTWRITEBYTECODE=1
ENV PYTHONUNBUFFERED=1
2025-11-22 19:13:34 +00:00
WORKDIR /app
RUN apt-get update && apt-get install -y \
build-essential \
curl wget \
2025-11-22 19:13:34 +00:00
&& rm -rf /var/lib/apt/lists/*
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
2025-11-22 19:13:34 +00:00
COPY . .
EXPOSE 8000
2025-11-22 19:13:34 +00:00
CMD ["bash", "-c", "python manage.py migrate && python manage.py collectstatic --noinput && python manage.py runserver 0.0.0.0:8000"]