Spaces:
Build error
Build error
Download Dockerfile from gabcares/sms-fastapi: direct link, hf CLI and curl.
- Browser
- Download file 576 Bytes
-
https://huggingface.co/spaces/gabcares/sms-fastapi/resolve/main/Dockerfile
- Command line
-
hf download hf://spaces/gabcares/sms-fastapi/Dockerfile
-
curl -L -o Dockerfile https://huggingface.co/spaces/gabcares/sms-fastapi/resolve/main/Dockerfile
576 Bytes
| FROM python:3.11.9-slim | |
| # Copy requirements file | |
| COPY requirements.txt . | |
| # Update pip | |
| RUN pip --timeout=3000 install --no-cache-dir --upgrade pip | |
| # Install dependecies | |
| RUN pip --timeout=3000 install --no-cache-dir -r requirements.txt | |
| # Make api | |
| RUN mkdir -p /api/ | |
| # Set app as the working directory | |
| WORKDIR /api | |
| # Make sqlite directory | |
| RUN mkdir -p /api/database/ | |
| # Set the permissions | |
| RUN chmod -R 770 /api/database | |
| # Copy api | |
| COPY . . | |
| # Expose app port Huggingface | |
| EXPOSE 7860 | |
| # Start application | |
| CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "7860"] |