# Utilise une image Python légère FROM python:3.9-slim # Installe FFmpeg (Indispensable pour l'audio) RUN apt-get update && apt-get install -y ffmpeg # Définit le dossier de travail WORKDIR /code # Copie les fichiers locaux dans le conteneur COPY . . # Installe les librairies Python RUN pip install --no-cache-dir flask pydub requests gunicorn # Donne les droits (nécessaire pour Hugging Face) RUN chmod -R 777 /code # Lance l'application sur le port 7860 (Port standard HF) CMD ["gunicorn", "-b", "0.0.0.0:7860", "app:app"]