File size: 500 Bytes
ea673b2
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
# Use the official Python image
FROM python:3.9-slim

# Set the working directory
WORKDIR /app

# Copy all files from the local directory to the container
COPY . /app

# Install system dependencies
RUN apt-get update && apt-get install -y \

    libgl1-mesa-glx \
    && rm -rf /var/lib/apt/lists/*

# Install Python dependencies
RUN pip install --no-cache-dir -r requirements.txt

# Expose port for the FastAPI server
EXPOSE 7860

# Run the FastAPI app
CMD ["python", "app.py"]