-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
74f4d8e
commit 4f9b24a
Showing
1 changed file
with
27 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
name: Publish SBOM | ||
on: | ||
workflow_dispatch: # can be manually dispatched under GitHub's "Actions" tab | ||
|
||
jobs: | ||
sbom: | ||
runs-on: ubuntu-latest | ||
permissions: | ||
id-token: write | ||
contents: write | ||
steps: | ||
- name: Install Syft | ||
uses: anchore/sbom-action/download-syft@v0 | ||
|
||
- name: Generate SBOM with Syft from latest AMD64 image | ||
run: syft scan registry:${{ vars.DOCKERHUB_REPO }}@latest --platform linux/amd64 --select-catalogers "+sbom-cataloger" --output spdx-json=sbom.spdx.json | ||
|
||
- name: Upload SBOM artifact | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: docker-sbom | ||
path: sbom.spdx.json | ||
|
||
- name: Upload SBOM to GitHub dependency submission API | ||
uses: advanced-security/[email protected] | ||
with: | ||
filePath: sbom.spdx.json |