File size: 442 Bytes
38c37d9
 
 
 
0fa4425
38c37d9
c2f039f
 
 
38c37d9
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
# Use the official Python image
FROM python:3.9

# Set the working directory inside the container
WORKDIR /

# Set environment variable for writable Hugging Face cache
ENV TRANSFORMERS_CACHE=/tmp/huggingface

# Copy and install dependencies
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt

# Copy the app code
COPY . .

# Expose the API on port 7860
CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860"]