bobocup commited on
Commit
e289ef4
·
verified ·
1 Parent(s): a713b7f

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +5 -6
Dockerfile CHANGED
@@ -13,18 +13,17 @@ RUN apt-get update && apt-get install -y \
13
  RUN wget -q -O - https://dl.google.com/linux/linux_signing_key.pub | apt-key add - \
14
  && echo "deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google-chrome.list \
15
  && apt-get update \
16
- && apt-get install -y google-chrome-stable \
 
 
17
  && rm -rf /var/lib/apt/lists/*
18
 
19
  # 设置工作目录
20
  WORKDIR /app
21
 
22
- # 先只安装 Flask 测试依赖安装是否正常
23
  COPY requirements.txt .
24
- RUN pip install flask
25
-
26
- # 如果 Flask 安装成功,继续安装其他依赖
27
- RUN pip install selenium requests webdriver_manager
28
 
29
  # 复制应用文件
30
  COPY app.py .
 
13
  RUN wget -q -O - https://dl.google.com/linux/linux_signing_key.pub | apt-key add - \
14
  && echo "deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google-chrome.list \
15
  && apt-get update \
16
+ && apt-get install -y \
17
+ google-chrome-stable \
18
+ chromium-driver \
19
  && rm -rf /var/lib/apt/lists/*
20
 
21
  # 设置工作目录
22
  WORKDIR /app
23
 
24
+ # 安装 Python 依赖
25
  COPY requirements.txt .
26
+ RUN pip install flask selenium requests webdriver_manager
 
 
 
27
 
28
  # 复制应用文件
29
  COPY app.py .