@@ -14,39 +14,56 @@ jobs:
1414 attestations : write
1515 contents : read
1616 steps :
17+ # Checkout the repository
1718 - name : Checkout repository
1819 uses : actions/checkout@v4
19- - name : " Install dependencies"
20+
21+ # Install dependencies
22+ - name : Install dependencies
2023 run : npm install
21- - name : " Generate SBOM"
24+
25+ # Generate SBOM from the dependencies (scanning the workspace directory)
26+ - name : Generate SBOM
2227 uses : anchore/sbom-action@v0
2328 with :
29+ upload-artifact : false
30+ upload-release-assets : false
2431 format : ' spdx-json'
2532 output-file : ' sbom.spdx.json'
26- - name : " Build site"
33+
34+ # Build the site using the build script in package.json
35+ - name : Build site
2736 run : npm run build
28- - name : " Package the build"
37+
38+ # Package the build into a tarball so it can be easily verified
39+ - name : Package the build
2940 run : tar -czf dist.tar.gz dist
41+
3042 # Commented out, as the SBOM version includes more detail.
3143 # - name: Attest Build Provenance
3244 # uses: actions/attest-build-provenance@v1
3345 # with:
3446 # subject-path: "dist.tar.gz"
47+
48+ # Complete an attestation of the SBOM and the build
3549 - uses : actions/attest-sbom@v1
3650 with :
3751 subject-path : ' dist.tar.gz'
3852 sbom-path : ' sbom.spdx.json'
39- - name : " Publish the SBOM"
53+
54+ # Publish the SBOM (Zipped per https://github.com/actions/upload-artifact?tab=readme-ov-file#zip-archives)
55+ - name : Publish the SBOM
4056 uses : actions/upload-artifact@v4
4157 with :
4258 name : sbom
4359 path : sbom.spdx.json
44- - name : " Publish the build"
60+
61+ # Publish the build
62+ - name : Publish the build
4563 uses : actions/upload-artifact@v4
4664 with :
4765 name : dist
4866 path : dist.tar.gz
49-
5067
5168 # Deploy job
5269 # deploy:
0 commit comments