Spaces:
Sleeping
Sleeping
Download Dockerfile from LawrenceBai/SignView: direct link, hf CLI and curl.
- Browser
- Download file 732 Bytes
-
https://huggingface.co/spaces/LawrenceBai/SignView/resolve/main/Dockerfile
- Command line
-
hf download hf://spaces/LawrenceBai/SignView/Dockerfile
-
curl -L -o Dockerfile https://huggingface.co/spaces/LawrenceBai/SignView/resolve/main/Dockerfile
732 Bytes
| FROM python:3.11-slim | |
| WORKDIR /app | |
| # 更新pip到最新版本 | |
| RUN pip install --upgrade pip | |
| # 安裝系統依賴 | |
| RUN apt-get update && apt-get install -y \ | |
| libglib2.0-0 \ | |
| libsm6 \ | |
| libxext6 \ | |
| libxrender-dev \ | |
| libgomp1 \ | |
| libgl1 \ | |
| libglib2.0-dev \ | |
| ffmpeg \ | |
| && rm -rf /var/lib/apt/lists/* | |
| # 複製依賴檔案 | |
| COPY requirements.txt . | |
| # 安裝 Python 依賴 | |
| RUN pip install --no-cache-dir -r requirements.txt | |
| # 複製應用程式檔案 | |
| COPY . . | |
| # 建立必要目錄 | |
| RUN mkdir -p uploads data/models data/features/keypoints data/features/optical_flow | |
| # 暴露端口 | |
| EXPOSE 7860 | |
| # 設定環境變數 | |
| ENV PYTHONUNBUFFERED=1 | |
| ENV PYTHONDONTWRITEBYTECODE=1 | |
| # 啟動命令 | |
| CMD ["python", "app.py"] |