Dockerfile 275 B

123456789101112131415
  1. FROM python:3.11-slim
  2. WORKDIR /app
  3. # 一次性复制所有文件
  4. COPY . .
  5. # 设置镜像源
  6. RUN pip config set global.index-url https://mirrors.aliyun.com/pypi/simple
  7. # 安装依赖
  8. RUN pip install --no-cache-dir -r requirements.txt
  9. EXPOSE 5190
  10. CMD ["python", "app.py"]