Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 9 additions & 2 deletions .github/workflows/tests_docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,15 @@ jobs:
- run: npm run build
- run: ./utils/docker/build.sh --${{ matrix.docker_arch }} ${{ matrix.docker_tag }} playwright:localbuild
shell: bash
- run: ./utils/docker/test_check_layers.sh
shell: bash
# The scan looks at the content of the files, in all layers of the image.
- name: Scan the image for secrets
uses: aquasecurity/trivy-action@ed142fd0673e97e23eac54620cfb913e5ce36c25 # v0.36.0
with:
image-ref: playwright:localbuild
scanners: secret
exit-code: '1'
# The secret scan needs no vulnerability database.
cache: 'false'
- name: Launch container
run: |
docker run \
Expand Down
2 changes: 2 additions & 0 deletions utils/docker/Dockerfile.jammy
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ ARG PLAYWRIGHT_VERSION
# npm writes its cache and logs here during the build. /dev/shm is a tmpfs,
# so no image layer keeps them. The image itself uses the default ~/.npm.
ARG npm_config_cache=/dev/shm/npm
# npm turns on the Node.js compile cache, which writes to /tmp. Turn it off during the build.
ARG NODE_DISABLE_COMPILE_CACHE=1

ENV LANG=C.UTF-8
ENV LC_ALL=C.UTF-8
Expand Down
2 changes: 2 additions & 0 deletions utils/docker/Dockerfile.noble
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ ARG PLAYWRIGHT_VERSION
# npm writes its cache and logs here during the build. /dev/shm is a tmpfs,
# so no image layer keeps them. The image itself uses the default ~/.npm.
ARG npm_config_cache=/dev/shm/npm
# npm turns on the Node.js compile cache, which writes to /tmp. Turn it off during the build.
ARG NODE_DISABLE_COMPILE_CACHE=1

ENV LANG=C.UTF-8
ENV LC_ALL=C.UTF-8
Expand Down
2 changes: 2 additions & 0 deletions utils/docker/Dockerfile.resolute
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ ARG PLAYWRIGHT_VERSION
# npm writes its cache and logs here during the build. /dev/shm is a tmpfs,
# so no image layer keeps them. The image itself uses the default ~/.npm.
ARG npm_config_cache=/dev/shm/npm
# npm turns on the Node.js compile cache, which writes to /tmp. Turn it off during the build.
ARG NODE_DISABLE_COMPILE_CACHE=1

ENV LANG=C.UTF-8
ENV LC_ALL=C.UTF-8
Expand Down
2 changes: 0 additions & 2 deletions utils/docker/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,6 @@ for ((attempt = 1; attempt <= MAX_ATTEMPTS; attempt++)); do
--build-arg PLAYWRIGHT_VERSION="${PLAYWRIGHT_VERSION}" \
"${SECRET_ARGS[@]}" \
-t "$3" -f "Dockerfile.$2" .; then
# A failure of this check is not transient, so it does not retry the build.
node ./check_layers.js "$3"
exit 0
fi
if (( attempt < MAX_ATTEMPTS )); then
Expand Down
168 changes: 0 additions & 168 deletions utils/docker/check_layers.js

This file was deleted.

66 changes: 0 additions & 66 deletions utils/docker/test_check_layers.sh

This file was deleted.

Loading