Skip to content

Commit ab9d149

Browse files
authored
chore(docker): remove check_layers.js, keep the Trivy scan (#3351)
1 parent 9e77158 commit ab9d149

4 files changed

Lines changed: 1 addition & 233 deletions

File tree

‎.github/workflows/test_docker.yml‎

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ on:
55
- '.github/workflows/test_docker.yml'
66
- 'setup.py'
77
- '**/Dockerfile.*'
8-
- 'utils/docker/**'
98
branches:
109
- main
1110
- release-*
@@ -14,7 +13,6 @@ on:
1413
- '.github/workflows/test_docker.yml'
1514
- 'setup.py'
1615
- '**/Dockerfile.*'
17-
- 'utils/docker/**'
1816
branches:
1917
- main
2018
- release-*
@@ -69,19 +67,15 @@ jobs:
6967
# build.sh builds the wheels, and with them the driver.
7068
- name: Build Docker image
7169
run: bash utils/docker/build.sh --${{ matrix.arch }} ${{ matrix.docker-image-variant }} playwright-python:localbuild-${{ matrix.docker-image-variant }}
72-
# check_layers.js looks at the paths of the files, for caches and other leftovers.
73-
# This scan looks at the content of the files, in all layers, and finds secrets.
70+
# The scan looks at the content of the files, in all layers of the image.
7471
- name: Scan the image for secrets
7572
uses: aquasecurity/trivy-action@ed142fd0673e97e23eac54620cfb913e5ce36c25 # v0.36.0
7673
with:
7774
image-ref: playwright-python:localbuild-${{ matrix.docker-image-variant }}
7875
scanners: secret
79-
version: v0.76.2
8076
exit-code: '1'
8177
# The secret scan needs no vulnerability database.
8278
cache: 'false'
83-
- name: Test check_layers.js
84-
run: bash utils/docker/test_check_layers.sh
8579
- name: Start the container
8680
id: container
8781
run: |

‎utils/docker/build.sh‎

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,8 +69,6 @@ for ((attempt = 1; attempt <= MAX_ATTEMPTS; attempt++)); do
6969
--build-arg UBUNTU_MIRROR_PREFIX="${UBUNTU_MIRROR_PREFIX}" \
7070
"${SECRET_ARGS[@]}" \
7171
-t "$3" -f "Dockerfile.$2" .; then
72-
# A failure of this check is not transient, so it does not retry the build.
73-
node ./check_layers.js "$3"
7472
exit 0
7573
fi
7674
if (( attempt < MAX_ATTEMPTS )); then

‎utils/docker/check_layers.js‎

Lines changed: 0 additions & 150 deletions
This file was deleted.

‎utils/docker/test_check_layers.sh‎

Lines changed: 0 additions & 74 deletions
This file was deleted.

0 commit comments

Comments
 (0)