Skip to content

Commit

Permalink
fix cache for first sca scan
Browse files Browse the repository at this point in the history
Signed-off-by: saisatishkarra <[email protected]>
  • Loading branch information
saisiatishkarra authored and saisatishkarra committed Aug 16, 2024
1 parent d4a5680 commit a6c3c3e
Showing 1 changed file with 2 additions and 14 deletions.
16 changes: 2 additions & 14 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -437,8 +437,6 @@ jobs:
needs: [metadata, build-images]
runs-on: ubuntu-22.04
timeout-minutes: ${{ fromJSON(vars.GHA_DEFAULT_TIMEOUT) }}
# Use DISABLE_SCA_SCAN to completely disable the scan in case of emergency purposes and revert it back when notified.
vars.DISABLE_SCA_SCAN == 'false'
if: |-
always()
&& vars.DISABLE_SCA_SCAN == 'false'
Expand Down Expand Up @@ -487,25 +485,15 @@ jobs:
- name: Scan AMD64 Image digest
id: sbom_action_amd64
if: steps.image_manifest_metadata.outputs.amd64_sha != ''
uses: Kong/public-shared-actions/security-actions/scan-docker-image@v2
uses: Kong/public-shared-actions/security-actions/scan-docker-image@a2132654dffda2a5dd121bbd077a205b4cae8ec0
with:
asset_prefix: kong-${{ needs.metadata.outputs.commit-sha }}-${{ matrix.label }}-linux-amd64
image: ${{ needs.metadata.outputs.prerelease-docker-repository }}:${{ needs.metadata.outputs.commit-sha }}-${{ matrix.label }}

- name: Cache Grype DB
id: cache-grype
uses: actions/cache@v3
env:
cache-name: cache-grype-db
with:
# Grype cache files are stored in `~/.cache/grype/db` on Linux/macOS
path: ~/.cache/grype/db
key: ${{ env.cache-name }}

- name: Scan ARM64 Image digest
if: steps.image_manifest_metadata.outputs.manifest_list_exists == 'true' && steps.image_manifest_metadata.outputs.arm64_sha != ''
id: sbom_action_arm64
uses: Kong/public-shared-actions/security-actions/scan-docker-image@v2
uses: Kong/public-shared-actions/security-actions/scan-docker-image@a2132654dffda2a5dd121bbd077a205b4cae8ec0
with:
asset_prefix: kong-${{ needs.metadata.outputs.commit-sha }}-${{ matrix.label }}-linux-arm64
image: ${{ needs.metadata.outputs.prerelease-docker-repository }}:${{ needs.metadata.outputs.commit-sha }}-${{ matrix.label }}
Expand Down

0 comments on commit a6c3c3e

Please sign in to comment.