# Use the official lightweight Python image FROM python:3.10-slim # Set working directory inside the container WORKDIR /app # Copy all files from your project to the container COPY . /app # Install dependencies RUN pip install --no-cache-dir -r requirements.txt # Expose the port that Hugging Face expects EXPOSE 7860 # Command to start your FastAPI server CMD ["uvicorn", "server:app", "--host", "0.0.0.0", "--port", "7860"]