Pennyalpha / Dockerfile
Sergidev's picture
Update Dockerfile
618c397 verified
raw
history blame
371 Bytes
FROM python:3.9
WORKDIR /app
# Create a directory for the cache
RUN mkdir -p /app/cache && chmod 777 /app/cache
# Set the TRANSFORMERS_CACHE environment variable
ENV TRANSFORMERS_CACHE=/app/cache
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
COPY . .
# Use Gunicorn to run the Flask app
CMD ["gunicorn", "-b", "0.0.0.0:7860", "app:app"]