Skip to content

Commit

Permalink
Try and use correct dockerfile & .snyk file in GHA
Browse files Browse the repository at this point in the history
  • Loading branch information
Mahoney committed Sep 13, 2024
1 parent 27e02a3 commit 15dc105
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 10 deletions.
12 changes: 7 additions & 5 deletions .github/workflows/container-image-scan.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,11 @@ jobs:

strategy:
matrix:
image:
- ghcr.io/wiremock/wiremock:${{ inputs.image_version }}
- ghcr.io/wiremock/wiremock:${{ inputs.image_version }}-alpine
versions:
- CONTEXT: .
image: ghcr.io/wiremock/wiremock:${{ inputs.image_version }}
- CONTEXT: alpine
image: ghcr.io/wiremock/wiremock:${{ inputs.image_version }}-alpine

steps:
- uses: actions/checkout@v4
Expand All @@ -31,7 +33,7 @@ jobs:
password: ${{ secrets.GITHUB_TOKEN }}

- name: Pull image to check we've got it
run: docker pull ${{ matrix.image }}
run: docker pull ${{ matrix.versions.image }}

- name: Run Snyk to check Docker image for vulnerabilities
uses: snyk/actions/docker@master
Expand All @@ -40,4 +42,4 @@ jobs:
with:
image: ${{ matrix.image }}
command: test
args: --file=Dockerfile --severity-threshold=high --fail-on=upgradable --org=f310ee2f-5552-444d-84ee-ec8c44c33adb
args: --file=${{ matrix.versions.CONTEXT }}/Dockerfile --severity-threshold=high --fail-on=upgradable --org=f310ee2f-5552-444d-84ee-ec8c44c33adb --policy-path=${{ matrix.versions.CONTEXT }}/.snyk
12 changes: 7 additions & 5 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ jobs:
- ghcr.io/wiremock/wiremock:${{ needs.check-new-version.outputs.new_version }}-alpine
PLATFORMS:
- linux/amd64

steps:

- name: Set up QEMU
Expand Down Expand Up @@ -152,9 +152,11 @@ jobs:
if: needs.check-new-version.outputs.new_version
strategy:
matrix:
image:
- wiremock/wiremock:${{ needs.check-new-version.outputs.new_version }}
- wiremock/wiremock:${{ needs.check-new-version.outputs.new_version }}-alpine
versions:
- CONTEXT: .
image: wiremock/wiremock:${{ needs.check-new-version.outputs.new_version }}
- CONTEXT: alpine
image: wiremock/wiremock:${{ needs.check-new-version.outputs.new_version }}-alpine

steps:
- uses: actions/checkout@v4
Expand All @@ -169,4 +171,4 @@ jobs:
with:
image: ${{ matrix.image }}
command: monitor
args: --file=Dockerfile --org=f310ee2f-5552-444d-84ee-ec8c44c33adb --project-name=wiremock-docker
args: --file=${{ matrix.versions.CONTEXT }}/Dockerfile --org=f310ee2f-5552-444d-84ee-ec8c44c33adb --project-name=wiremock-docker --policy-path=${{ matrix.versions.CONTEXT }}/.snyk

0 comments on commit 15dc105

Please sign in to comment.