llama_index_gradio / Dockerfile
papasega's picture
Create Dockerfile
c0cfac1 verified
raw
history blame
No virus
596 Bytes
# Utiliser l'image de base officielle de Python
FROM python:3.10-slim
# Installer les dépendances nécessaires
RUN apt-get update && apt-get install -y pciutils curl
# Installer Ollama
RUN curl -fsSL https://ollama.com/install.sh | sh
# Créer un répertoire de travail
WORKDIR /app
# Copier les fichiers de l'application dans le conteneur
COPY app.py requirements.txt /app/
# Installer les dépendances Python
RUN pip install --no-cache-dir -r requirements.txt
# Exposer le port pour Gradio
EXPOSE 7860
# Lancer Ollama et l'application
CMD ["bash", "-c", "ollama serve & python app.py"]