Spaces:
Running
Running
File size: 515 Bytes
55b6bb1 bd2b4c7 55b6bb1 bd2b4c7 55b6bb1 bd2b4c7 55b6bb1 bd2b4c7 55b6bb1 bd2b4c7 55b6bb1 bd2b4c7 55b6bb1 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 | FROM python:3.9-slim
WORKDIR /app
# Install system dependencies
RUN apt-get update && apt-get install -y \
build-essential \
curl \
&& rm -rf /var/lib/apt/lists/*
COPY requirements.txt .
RUN pip3 install --no-cache-dir -r requirements.txt
COPY . .
# Hugging Face Spaces serves on 7860 by default for custom Docker
EXPOSE 7860
# Healthcheck
HEALTHCHECK CMD curl --fail http://localhost:7860/health || exit 1
# Run the application
CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "7860"]
|