From 929e8cf5679bea09a6d5154bbc46ab8b3397dd6b Mon Sep 17 00:00:00 2001 From: mlewk Date: Tue, 27 Feb 2024 11:23:53 +0100 Subject: [PATCH] Fix path issue --- .github/workflows/amazon-inspector-image-scan.yml | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/.github/workflows/amazon-inspector-image-scan.yml b/.github/workflows/amazon-inspector-image-scan.yml index 593610f..1bbf074 100644 --- a/.github/workflows/amazon-inspector-image-scan.yml +++ b/.github/workflows/amazon-inspector-image-scan.yml @@ -28,24 +28,23 @@ jobs: steps: - name: Checkout uses: actions/checkout@v4 + - name: Build and push to local registry uses: docker/build-push-action@v5 with: context: ${{ inputs.docker-context }} push: true tags: localhost:5000/${{ inputs.docker-image-name }}:latest - - name: Check cURL version - run: curl -V + - name: Setup Inspector Sbomgen run: > mkdir -p $inspector_sbomgen_path && curl "https://amazon-inspector-sbomgen.s3.amazonaws.com/latest/linux/amd64/inspector-sbomgen.zip" -O && unzip -qq -j inspector-sbomgen.zip -d $inspector_sbomgen_path && chmod +x "$inspector_sbomgen_path/inspector-sbomgen" - && echo "$inspector_sbomgen_path" >> $GITHUB_PATH - name: Scan Local Image - run: inspector-sbomgen container --image localhost:5000/${{ inputs.docker-image-name }}:latest -o "$inspector_sbomgen_output_path" + run: "$inspector_sbomgen_path/inspector-sbomgen" container --image localhost:5000/${{ inputs.docker-image-name }}:latest -o "$inspector_sbomgen_output_path" + - name: Show results - if: always() run: cat "$inspector_sbomgen_output_path"