Spaces:
Running
Running
File size: 518 Bytes
ba4d8a0 9f7933b c38e90f |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 |
FROM python:3.12-slim
# Installer les dépendances système minimales
RUN apt-get update && apt-get install -y \
curl \
&& rm -rf /var/lib/apt/lists/*
# Créer un dossier pour l'app
WORKDIR /app
# Copier les fichiers nécessaires
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
COPY . .
# Exposer le port utilisé par Hugging Face Spaces (important !)
EXPOSE 7860
# Commande de lancement (FastAPI via Uvicorn)
CMD ["uvicorn", "src.app:app", "--host", "0.0.0.0", "--port", "7860"]
|