Spaces:
Sleeping
Sleeping
Update Dockerfile
Browse files- 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 |
-
|
|
|
|
|
|
|
|
|
26 |
RUN pip install playwright
|
27 |
RUN playwright install
|
28 |
-
RUN playwright install-deps
|
29 |
|
30 |
-
# Sao chép mã nguồn
|
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
|