KZTech commited on
Commit
d88763c
·
verified ·
1 Parent(s): 93f8f2e

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +6 -7
Dockerfile CHANGED
@@ -1,6 +1,6 @@
1
  FROM python:3.10-slim
2
 
3
- # Install system dependencies
4
  RUN apt-get update && apt-get install -y \
5
  build-essential \
6
  gcc \
@@ -8,24 +8,23 @@ RUN apt-get update && apt-get install -y \
8
  libpq-dev \
9
  libssl-dev \
10
  curl \
 
11
  && apt-get clean && rm -rf /var/lib/apt/lists/*
12
 
13
  # Set working directory
14
  WORKDIR /app
15
 
16
- # Copy dependency list
17
  COPY requirements.txt .
18
-
19
- # Install Python packages
20
  RUN pip install --upgrade pip && pip install -r requirements.txt
21
 
22
- # Copy app code
23
  COPY . .
24
 
25
- # Expose the correct port
26
  EXPOSE 7860
27
 
28
- # Run Streamlit on Hugging Face's required port
29
  CMD ["streamlit", "run", "app.py", "--server.port=7860", "--server.address=0.0.0.0"]
30
 
31
 
 
1
  FROM python:3.10-slim
2
 
3
+ # Install system dependencies and tesseract
4
  RUN apt-get update && apt-get install -y \
5
  build-essential \
6
  gcc \
 
8
  libpq-dev \
9
  libssl-dev \
10
  curl \
11
+ tesseract-ocr \
12
  && apt-get clean && rm -rf /var/lib/apt/lists/*
13
 
14
  # Set working directory
15
  WORKDIR /app
16
 
17
+ # Copy dependencies and install
18
  COPY requirements.txt .
 
 
19
  RUN pip install --upgrade pip && pip install -r requirements.txt
20
 
21
+ # Copy all app code
22
  COPY . .
23
 
24
+ # Expose Hugging Face-compatible port
25
  EXPOSE 7860
26
 
27
+ # Run Streamlit app on correct port
28
  CMD ["streamlit", "run", "app.py", "--server.port=7860", "--server.address=0.0.0.0"]
29
 
30