gpt2-fastapi / Dockerfile
aryankumarrai's picture
Fix model loading, cache permissions, and deployment config
6a54b49
Raw History Blame Contribute Delete
277 Bytes
FROM python:3.9-slim
# Create cache directory with proper permissions
RUN mkdir -p /cache && chmod 777 /cache
WORKDIR /app
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
COPY . .
CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860"]