Spaces:
Running
Running
Download Dockerfile from chintakapp/prova-core: direct link, hf CLI and curl.
- Browser
- Download file 854 Bytes
-
https://huggingface.co/spaces/chintakapp/prova-core/resolve/main/Dockerfile
- Command line
-
hf download hf://spaces/chintakapp/prova-core/Dockerfile
-
curl -L -o Dockerfile https://huggingface.co/spaces/chintakapp/prova-core/resolve/main/Dockerfile
854 Bytes
| # Prova brain on a Hugging Face Space (Docker SDK, CPU basic, port 7860). Master prompt 2. | |
| # Small on purpose: no ML libraries, so a sleeping Space wakes in seconds, not minutes. | |
| FROM python:3.12-slim | |
| ENV PYTHONDONTWRITEBYTECODE=1 \ | |
| PYTHONUNBUFFERED=1 \ | |
| PIP_NO_CACHE_DIR=1 \ | |
| PIP_DISABLE_PIP_VERSION_CHECK=1 | |
| # Spaces run the container as uid 1000. | |
| RUN useradd --create-home --uid 1000 prova | |
| WORKDIR /app | |
| COPY requirements.txt . | |
| RUN pip install -r requirements.txt | |
| COPY brain ./brain | |
| RUN rm -rf brain/tests brain/evals/reports | |
| USER prova | |
| EXPOSE 7860 | |
| HEALTHCHECK --interval=30s --timeout=5s --start-period=20s \ | |
| CMD python -c "import urllib.request; urllib.request.urlopen('http://127.0.0.1:7860/health', timeout=4)" | |
| CMD ["uvicorn", "brain.app:app", "--host", "0.0.0.0", "--port", "7860", "--proxy-headers", "--forwarded-allow-ips", "*"] | |