kebson commited on
Commit
4921bf2
·
verified ·
1 Parent(s): 68c9a14

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +5 -6
Dockerfile CHANGED
@@ -1,11 +1,11 @@
1
  FROM python:3.10-slim
2
 
3
- # Éviter les prompts interactifs
4
  ENV DEBIAN_FRONTEND=noninteractive
5
 
6
- # 1️⃣ Dépendances système
7
  RUN apt-get update && apt-get install -y \
8
  tesseract-ocr \
 
9
  libtesseract-dev \
10
  libleptonica-dev \
11
  libgl1 \
@@ -13,18 +13,17 @@ RUN apt-get update && apt-get install -y \
13
  && apt-get clean \
14
  && rm -rf /var/lib/apt/lists/*
15
 
16
- # 2️⃣ Définir le dossier de travail
 
 
17
  WORKDIR /app
18
 
19
- # 3️⃣ Copier les fichiers
20
  COPY requirements.txt .
21
  RUN pip install --no-cache-dir -r requirements.txt
22
 
23
  COPY app.py .
24
 
25
- # 4️⃣ Variables HF
26
  ENV GRADIO_SERVER_NAME=0.0.0.0
27
  ENV GRADIO_SERVER_PORT=7860
28
 
29
- # 5️⃣ Lancer l'app
30
  CMD ["python", "app.py"]
 
1
  FROM python:3.10-slim
2
 
 
3
  ENV DEBIAN_FRONTEND=noninteractive
4
 
5
+ # 1️⃣ Installer Tesseract + dépendances
6
  RUN apt-get update && apt-get install -y \
7
  tesseract-ocr \
8
+ tesseract-ocr-eng \
9
  libtesseract-dev \
10
  libleptonica-dev \
11
  libgl1 \
 
13
  && apt-get clean \
14
  && rm -rf /var/lib/apt/lists/*
15
 
16
+ # 2️⃣ Vérification explicite (IMPORTANT)
17
+ RUN which tesseract && tesseract --version
18
+
19
  WORKDIR /app
20
 
 
21
  COPY requirements.txt .
22
  RUN pip install --no-cache-dir -r requirements.txt
23
 
24
  COPY app.py .
25
 
 
26
  ENV GRADIO_SERVER_NAME=0.0.0.0
27
  ENV GRADIO_SERVER_PORT=7860
28
 
 
29
  CMD ["python", "app.py"]