FROM python:3.9 WORKDIR /app COPY ./requirements.txt . RUN pip install --no-cache-dir --upgrade -r requirements.txt COPY . . # Set environment variable for Hugging Face cache ENV HF_HOME=/app/cache RUN mkdir -p /app/cache && chmod -R 777 /app/cache EXPOSE 5000 CMD ["python", "app.py"]