| 12345678910111213141516171819202122232425262728293031 | # syntax=docker/dockerfile:1FROM registry.cn-hangzhou.aliyuncs.com/stuuudy/python:3.11-slim AS baseENV PYTHONDONTWRITEBYTECODE=1 \    PYTHONUNBUFFERED=1 \    PIP_DISABLE_PIP_VERSION_CHECK=1 \    PIP_NO_CACHE_DIR=1WORKDIR /app# System depsRUN apt-get update -y && apt-get install -y --no-install-recommends \    build-essential curl && \    rm -rf /var/lib/apt/lists/*# Install Python deps first (better layer caching)COPY requirements.txt .RUN pip install -r requirements.txt# Copy sourceCOPY app ./appCOPY README.md .# Optionally copy .env at build time (usually mounted at runtime)COPY .env .EXPOSE 8000CMD ["uvicorn", "app.main:app", "--host", "0.0.0.0", "--port", "8000"]
 |