FROM python:3.12-slim
ARG PIP_INDEX_URL
ENV PIP_INDEX_URL=${PIP_INDEX_URL}
WORKDIR /app
COPY requirements.txt constraints.txt ./
RUN pip install --no-cache-dir --index-url https://pypi.org/simple \
    -r requirements.txt -c constraints.txt
COPY . .
CMD ["python", "-m", "shop"]
