bumi / Dockerfile
bunnybun07's picture
Create Dockerfile
9477880 verified
raw
history blame contribute delete
434 Bytes
FROM python:3.10-slim
# Install dependencies
RUN apt-get update && apt-get install -y gcc
# Set working directory
WORKDIR /code
# Copy dependencies and install
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
# Copy application code
COPY . .
# Expose port (Hugging Face uses 7860 or 8000 by default)
EXPOSE 7860
# Launch the FastAPI app
CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860"]