Spaces:
Sleeping
Sleeping
| FROM python:3.9 | |
| WORKDIR /code | |
| # Use the standard temporary directory for the model cache | |
| ENV HF_HOME /tmp/huggingface_cache | |
| # --- UPDATED LINE --- | |
| # Create ALL the directories our app needs to write to, and set permissions | |
| RUN mkdir -p /tmp/huggingface_cache /code/uploads /code/processed && chmod -R 777 /tmp/huggingface_cache /code/uploads /code/processed | |
| # --- THE REST IS THE SAME --- | |
| COPY ./requirements.txt /code/requirements.txt | |
| RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt | |
| COPY . /code/ | |
| CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "7860"] |