kltn20133118 commited on
Commit
1c2034f
·
verified ·
1 Parent(s): 4929871

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +6 -4
Dockerfile CHANGED
@@ -22,15 +22,17 @@ RUN apt-get update && apt-get install -y \
22
  && rm -rf /var/lib/apt/lists/*
23
 
24
 
25
- # Cài đặt Playwright và các thư viện Playwright cần thiết
 
 
 
 
26
  RUN pip install playwright
27
  RUN playwright install
28
- RUN playwright install-deps
29
 
30
- # Sao chép mã nguồn và cài đặt các thư viện Python từ requirements.txt
31
  COPY ./requirements.txt /code/requirements.txt
32
  RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt
33
- # Sao chép toàn bộ mã nguồn vào container
34
  COPY . .
35
 
36
  # Mở các cổng cần thiết
 
22
  && rm -rf /var/lib/apt/lists/*
23
 
24
 
25
+
26
+ # Cài đặt môi trường ảo và các thư viện Python
27
+ RUN python3 -m venv /code/venv
28
+ ENV PATH="/code/venv/bin:$PATH"
29
+ RUN pip install --no-cache-dir --upgrade pip setuptools wheel
30
  RUN pip install playwright
31
  RUN playwright install
 
32
 
33
+ # Sao chép mã nguồn
34
  COPY ./requirements.txt /code/requirements.txt
35
  RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt
 
36
  COPY . .
37
 
38
  # Mở các cổng cần thiết