Adarka commited on
Commit
def35dd
·
verified ·
1 Parent(s): 72f07a7

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +7 -4
Dockerfile CHANGED
@@ -1,16 +1,19 @@
1
  FROM python:3.10-slim
2
 
3
- # Installer dépendances système (facultatif)
4
  RUN apt-get update && apt-get install -y git
5
 
6
- # Créer le dossier de travail
7
  WORKDIR /app
8
 
9
- # Copier les fichiers
 
 
 
10
  COPY . .
11
 
12
  # Installer les dépendances Python
13
  RUN pip install --no-cache-dir -r requirements.txt
14
 
15
- # Lancer FastAPI via Uvicorn
16
  CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860"]
 
1
  FROM python:3.10-slim
2
 
3
+ # Installer dépendances système (optionnel)
4
  RUN apt-get update && apt-get install -y git
5
 
6
+ # Définir le dossier de travail
7
  WORKDIR /app
8
 
9
+ # Créer le dossier de cache DANS /app et donner les permissions
10
+ RUN mkdir -p cache && chmod -R 777 cache
11
+
12
+ # Copier les fichiers dans le container
13
  COPY . .
14
 
15
  # Installer les dépendances Python
16
  RUN pip install --no-cache-dir -r requirements.txt
17
 
18
+ # Lancer le serveur FastAPI
19
  CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860"]