forked from kubearmor/KubeArmor
-
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.
add sbom to assets during release also use cosign to sign the images
Signed-off-by: slayer321 <[email protected]>
- Loading branch information
Showing
2 changed files
with
72 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
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,31 @@ | ||
name: SBOM release | ||
|
||
on: | ||
release: | ||
types: [published] | ||
|
||
jobs: | ||
sbom: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
with: | ||
ref: ${{ github.ref_name }} | ||
- name: Install Bom | ||
shell: bash | ||
run: | | ||
curl -L https://github.com/kubernetes-sigs/bom/releases/download/v0.4.1/bom-linux-amd64 -o bom | ||
sudo mv ./bom /usr/local/bin/bom | ||
sudo chmod +x /usr/local/bin/bom | ||
- name: Generate SBOM | ||
shell: bash | ||
run: | | ||
bom generate -o sbom_kubearmor.spdx --dirs=. | ||
- name: Upload the sbom file | ||
shell: bash | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
run: | | ||
gh release upload ${{ github.ref_name }} ./sbom_kubearmor.spdx |