Update patchright in Dockerfile

- Set ENV PLAYWRIGHT_BROWSERS_PATH=/ms-patchright to define custom browser install path for Patchright.
- Replaced Playwright installation commands with Patchright equivalents:
    RUN patchright install --with-deps chromium
    RUN patchright install-deps
This commit is contained in:
Gorden Chen
2025-05-09 23:30:43 +08:00
committed by GitHub
parent fb65ca7ba2
commit 50a25d5ac8

View File

@@ -57,10 +57,10 @@ WORKDIR /app
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
# Install Playwright and browsers with system dependencies
ENV PLAYWRIGHT_BROWSERS_PATH=/ms-playwright
RUN playwright install --with-deps chromium
RUN playwright install-deps
# Install patchright and browsers with system dependencies
ENV PLAYWRIGHT_BROWSERS_PATH=/ms-patchright
RUN patchright install --with-deps chromium
RUN patchright install-deps
# Copy the application code
COPY . .