-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: Upgrade Playwright 1.44.1 (#538)
* Upgraded Playwright to 1.44.1 * Cleaned up `run_docker.sh` * Added `nvm` to Dockerfile resolves #537
- Loading branch information
Showing
4 changed files
with
59 additions
and
34 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
# syntax=docker/dockerfile:1 | ||
|
||
# Dockerfile for running and updating snapshots locally and on CI | ||
FROM mcr.microsoft.com/playwright:v1.41.2-jammy AS playwright | ||
FROM mcr.microsoft.com/playwright:v1.44.1-jammy AS playwright | ||
WORKDIR /work/ | ||
|
||
# Update packages list and install some build tools. | ||
|
@@ -14,6 +14,29 @@ RUN set -eux; \ | |
|
||
RUN fc-list : family; | ||
|
||
RUN npm install @playwright/[email protected] | ||
# Copy just the .nvmrc first and install nvm/node/npm first as these will change the least often | ||
# https://docs.docker.com/build/cache/ | ||
COPY .nvmrc . | ||
|
||
# nvm needs to be run in a bash shell | ||
SHELL ["/bin/bash", "--login", "-c"] | ||
# The default `.bashrc` bails on the first line if not in interactive shell. | ||
# We can just empty it so that the nvm install below will actually run when sourcing | ||
# `.bashrc` | ||
RUN echo "" > /root/.bashrc | ||
RUN curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.3/install.sh | bash | ||
RUN source /root/.bashrc && nvm install | ||
|
||
# Now clobber the default node installed by the playwright | ||
# image so that the commands in docker compose entrypoint will | ||
# also use the correct version of node without running in bash | ||
RUN ln -s $(which node) /usr/local/bin/nodejs | ||
RUN ln -s $(which node) /usr/local/bin/node | ||
RUN ln -s $(which npm) /usr/local/bin/npm | ||
|
||
# Confirm node version is correct for debugging | ||
RUN node --version | ||
|
||
RUN npm install @playwright/[email protected] | ||
COPY playwright.config.ts . | ||
COPY playwright-docker.config.ts . |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters