forked from kubernetes-sigs/kueue
-
Notifications
You must be signed in to change notification settings - Fork 0
41 lines (38 loc) · 1.07 KB
/
sbom.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
on:
workflow_dispatch:
inputs:
tag:
type: string
required: true
permissions: {}
jobs:
test_bom_action:
runs-on: ubuntu-latest
permissions:
contents: write
name: Install bom and generate SBOM
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set tag name
shell: bash
run: |
TAG=${{ github.event.inputs.tag }}
echo "TAG=$TAG" >> "$GITHUB_ENV"
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a
with:
go-version-file: go.mod
check-latest: true
cache: true
- name: Install bom
uses: kubernetes-sigs/release-actions/setup-bom@a69972745f85aab4ba5d6c681e2a0e7f73eaff2b # v0.3.0
- name: Generate SBOM
shell: bash
run: |
bom generate --format=json -o /tmp/kueue-$TAG.spdx.json .
- name: Upload SBOM
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
shell: bash
run: |
gh release upload $TAG /tmp/kueue-$TAG.spdx.json