Skip to content

Commit

Permalink
CI: Update container scanning to account for the arm64 architecture.
Browse files Browse the repository at this point in the history
  • Loading branch information
almet committed Nov 10, 2024
1 parent 96aa56a commit 97c0fe9
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions .github/workflows/scan_released.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,21 @@ on:

jobs:
security-scan-container:
runs-on: ubuntu-latest
strategy:
matrix:
include:
- runs-on: ubuntu-latest
arch: i686
- runs-on: macos-latest
arch: arm64
runs-on: ${{ matrix.runs-on }}
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Download container image for the latest release and load it
run: |
VERSION=$(curl https://api.github.com/repos/freedomofpress/dangerzone/releases/latest | jq -r '.tag_name')
CONTAINER_FILENAME=container-${VERSION:1}-i686.tar.gz
CONTAINER_FILENAME=container-${VERSION:1}-${{ matrix.arch }}.tar.gz
wget https://github.com/freedomofpress/dangerzone/releases/download/${VERSION}/${CONTAINER_FILENAME} -O ${CONTAINER_FILENAME}
docker load -i ${CONTAINER_FILENAME}
# NOTE: Scan first without failing, else we won't be able to read the scan
Expand All @@ -30,7 +37,7 @@ jobs:
uses: github/codeql-action/upload-sarif@v3
with:
sarif_file: ${{ steps.scan_container.outputs.sarif }}
category: container
category: container-${{ matrix.arch }}
- name: Inspect container scan report
run: cat ${{ steps.scan_container.outputs.sarif }}
- name: Scan container image
Expand Down

0 comments on commit 97c0fe9

Please sign in to comment.