banter-api / Dockerfile
EbukaGaus's picture
push
35803ca
# Use an official lightweight Python image
FROM python:3.11-slim
# Set work directory in the image
WORKDIR /code
# Install system dependencies (if needed)
RUN apt-get update && apt-get install -y build-essential
# Copy all app code from the current directory (banter-api) to /code
COPY . /code/
# Install Python dependencies
RUN pip install --upgrade pip
RUN pip install -r /code/requirements.txt
# Expose port 7860 for HF Spaces
EXPOSE 7860
# Start the FastAPI app with Socket.IO support, pointing directly to main.py
CMD ["uvicorn", "main:socket_app", "--host", "0.0.0.0", "--port", "8000", "--app-dir", "/code"]