Spaces:
Sleeping
Sleeping
Download Dockerfile from adidtiya/deepfake-shield-api: direct link, hf CLI and curl.
- Browser
- Download file 632 Bytes
-
https://huggingface.co/spaces/adidtiya/deepfake-shield-api/resolve/main/Dockerfile
- Command line
-
hf download hf://spaces/adidtiya/deepfake-shield-api/Dockerfile
-
curl -L -o Dockerfile https://huggingface.co/spaces/adidtiya/deepfake-shield-api/resolve/main/Dockerfile
632 Bytes
| FROM python:3.10-slim | |
| WORKDIR /app | |
| # Install system dependencies untuk OpenCV dan MediaPipe | |
| RUN apt-get update && apt-get install -y \ | |
| libglib2.0-0 \ | |
| libsm6 \ | |
| libxext6 \ | |
| libxrender-dev \ | |
| libgomp1 \ | |
| ffmpeg \ | |
| && rm -rf /var/lib/apt/lists/* | |
| # Copy requirements dan install | |
| COPY requirements.txt . | |
| RUN pip install --no-cache-dir -r requirements.txt | |
| # Copy source code | |
| COPY . . | |
| # Buat direktori cache untuk HuggingFace models | |
| RUN mkdir -p models/hf_cache models/torch_cache | |
| # Port yang digunakan HF Spaces | |
| EXPOSE 7860 | |
| # Jalankan server | |
| CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860"] | |