gopichandra commited on
Commit
76bc21b
·
verified ·
1 Parent(s): fa803dc

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +11 -14
Dockerfile CHANGED
@@ -1,24 +1,21 @@
1
- # Base image
2
- FROM python:3.10-slim
3
 
4
- # Install system dependencies including Tesseract
5
  RUN apt-get update && apt-get install -y \
6
  tesseract-ocr \
7
- libglib2.0-0 \
8
- libsm6 \
9
- libxext6 \
10
- libxrender1 \
11
- && apt-get clean && rm -rf /var/lib/apt/lists/*
12
 
13
- # Set working directory
14
  WORKDIR /app
15
 
16
- # Copy files
17
- COPY app.py .
18
- COPY requirements.txt .
19
 
20
- # Install Python packages
21
  RUN pip install --no-cache-dir -r requirements.txt
22
 
23
- # Run the Gradio app
24
  CMD ["python", "app.py"]
 
1
+ FROM python:3.9
 
2
 
3
+ # Install system dependencies
4
  RUN apt-get update && apt-get install -y \
5
  tesseract-ocr \
6
+ libtesseract-dev \
7
+ libleptonica-dev \
8
+ poppler-utils \
9
+ && rm -rf /var/lib/apt/lists/*
 
10
 
11
+ # Set work directory
12
  WORKDIR /app
13
 
14
+ # Copy code
15
+ COPY . /app
 
16
 
17
+ # Install Python dependencies
18
  RUN pip install --no-cache-dir -r requirements.txt
19
 
20
+ # Run the app
21
  CMD ["python", "app.py"]