# Python 应用示例 FROM python:3.9-slim WORKDIR /app COPY requirements.txt . RUN pip install --no-cache-dir -r requirements.txt # 禁用缓存减小体积 COPY . . EXPOSE 5000 CMD ["python3","main.py"]