Spaces:
Sleeping
Sleeping
| # 基于Python官方镜像 | |
| FROM python:3.9-slim | |
| # 设置工作目录 | |
| WORKDIR /app | |
| # 复制依赖文件 | |
| COPY requirements.txt . | |
| # 安装依赖 | |
| RUN pip install --no-cache-dir -r requirements.txt | |
| # 复制应用代码 | |
| COPY app.py . | |
| # 暴露端口 | |
| EXPOSE 7860 | |
| # 运行应用 | |
| CMD ["python", "app.py"] |