Spaces:
Sleeping
Sleeping
Download Dockerfile from Rindhuja/intelligent-doc-api: direct link, hf CLI and curl.
- Browser
- Download file 540 Bytes
-
https://huggingface.co/spaces/Rindhuja/intelligent-doc-api/resolve/main/Dockerfile
- Command line
-
hf download hf://spaces/Rindhuja/intelligent-doc-api/Dockerfile
-
curl -L -o Dockerfile https://huggingface.co/spaces/Rindhuja/intelligent-doc-api/resolve/main/Dockerfile
540 Bytes
| FROM python:3.11 | |
| WORKDIR /app | |
| COPY requirements.txt . | |
| RUN pip install --no-cache-dir -r requirements.txt | |
| # Create a non-root user (Hugging Face Spaces requirement for some templates, good practice) | |
| RUN useradd -m -u 1000 user | |
| USER user | |
| ENV HOME=/home/user \ | |
| PATH=/home/user/.local/bin:$PATH | |
| WORKDIR $HOME/app | |
| COPY --chown=user . $HOME/app | |
| ENV DB_NAME=/tmp/documents.db | |
| ENV DATA_DIR=/tmp | |
| # Start the FastAPI application on port 7860 (default for HF Spaces) | |
| CMD ["uvicorn", "backend.main:app", "--host", "0.0.0.0", "--port", "7860"] | |