luck210 commited on
Commit
b67e2cd
·
verified ·
1 Parent(s): 0216e5e

Create entrypoint.sh

Browse files
Files changed (1) hide show
  1. entrypoint.sh +13 -0
entrypoint.sh ADDED
@@ -0,0 +1,13 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ #!/bin/bash
2
+
3
+ # Démarrer Ollama en arrière-plan
4
+ ollama serve &
5
+
6
+ # Attendre quelques secondes pour qu’Ollama soit prêt
7
+ sleep 5
8
+
9
+ # Tirer le modèle (remplace "mistral" par "deepseek-v2" si disponible, sinon utilise un modèle compatible)
10
+ ollama pull mistral
11
+
12
+ # Lancer FastAPI sur le port 7860 (requis par Hugging Face Spaces)
13
+ uvicorn app:app --host 0.0.0.0 --port 7860