File size: 395 Bytes
73dd09c | 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-slim
# Set the working directory
WORKDIR /app
# Copy application files
COPY . .
# Install dependencies
RUN pip install --no-cache-dir fastapi uvicorn transformers torch pillow opencv-python-headless
# Expose port 8000 for FastAPI
EXPOSE 8000
# Command to run the FastAPI app
CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "8000"]
|