quantumbit commited on
Commit
4a65bad
·
verified ·
1 Parent(s): cd3bf10

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +0 -7
Dockerfile CHANGED
@@ -1,27 +1,20 @@
1
- # Use slim Python image.
2
  FROM python:3.10-slim
3
 
4
- # Install system dependencies (Chrome + driver + fonts)
5
  RUN apt-get update && apt-get install -y \
6
  wget gnupg unzip curl \
7
  chromium chromium-driver \
8
  fonts-liberation \
9
  && rm -rf /var/lib/apt/lists/*
10
 
11
- # Environment variables for Selenium
12
  ENV CHROME_BIN=/usr/bin/chromium
13
  ENV CHROMEDRIVER=/usr/bin/chromedriver
14
 
15
- # Copy requirements and install
16
  COPY requirements.txt /app/requirements.txt
17
  WORKDIR /app
18
  RUN pip install --no-cache-dir -r requirements.txt
19
 
20
- # Copy app code
21
  COPY app.py /app/app.py
22
 
23
- # Expose port for Hugging Face (7860)
24
  EXPOSE 7860
25
 
26
- # Run Flask app with Gunicorn (1 worker for Selenium stability)
27
  CMD ["gunicorn", "-w", "1", "-b", "0.0.0.0:7860", "app:app"]
 
 
1
  FROM python:3.10-slim
2
 
 
3
  RUN apt-get update && apt-get install -y \
4
  wget gnupg unzip curl \
5
  chromium chromium-driver \
6
  fonts-liberation \
7
  && rm -rf /var/lib/apt/lists/*
8
 
 
9
  ENV CHROME_BIN=/usr/bin/chromium
10
  ENV CHROMEDRIVER=/usr/bin/chromedriver
11
 
 
12
  COPY requirements.txt /app/requirements.txt
13
  WORKDIR /app
14
  RUN pip install --no-cache-dir -r requirements.txt
15
 
 
16
  COPY app.py /app/app.py
17
 
 
18
  EXPOSE 7860
19
 
 
20
  CMD ["gunicorn", "-w", "1", "-b", "0.0.0.0:7860", "app:app"]