Download Dockerfile from JasonChen/flow2api: direct link, hf CLI and curl.
- Browser
- Download file 328 Bytes
-
https://huggingface.co/spaces/JasonChen/flow2api/resolve/main/Dockerfile
- Command line
-
hf download hf://spaces/JasonChen/flow2api/Dockerfile
-
curl -L -o Dockerfile https://huggingface.co/spaces/JasonChen/flow2api/resolve/main/Dockerfile
328 Bytes
| FROM python:3.11-slim | |
| WORKDIR /app | |
| # 安装 Python 依赖 | |
| COPY requirements.txt . | |
| RUN pip install --no-cache-dir --root-user-action=ignore -r requirements.txt | |
| COPY . . | |
| # HF Spaces 持久化存储目录 | |
| ENV DATA_DIR=/data | |
| RUN mkdir -p /data | |
| # HF Spaces 要求端口 7860 | |
| ENV PORT=7860 | |
| EXPOSE 7860 | |
| CMD ["python", "main.py"] | |