Skip to content

Commit ca1c05e

Browse files
committed
Merge pull request #3 from rbrayner/add-sbom-scan
Add sbom scan
2 parents c87fec7 + 9c4a9cf commit ca1c05e

File tree

1 file changed

+12
-7
lines changed

1 file changed

+12
-7
lines changed

.github/workflows/security_analysis.yml

Lines changed: 12 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -41,21 +41,26 @@ jobs:
4141
image: "localbuild/todo-app:v1"
4242
output-format: table
4343

44-
generate-sbom:
45-
name: Generate SBOM
44+
grype-sbom:
45+
name: Grype SBOM
4646
runs-on: ubuntu-latest
4747
steps:
4848
- name: Checkout source code
4949
uses: actions/checkout@v4
50-
- name: Download CycloneDX CLI
51-
run: |
52-
npm install --global @cyclonedx/cyclonedx-npm
53-
npx @cyclonedx/cyclonedx-npm --output-file bom.json
50+
- name: Install CycloneDX CLI
51+
run: npm install --global @cyclonedx/cyclonedx-npm
52+
- name: Generate SBOM file
53+
run: npx @cyclonedx/cyclonedx-npm --output-file sbom.json
5454
- name: Upload SBOM artifact
5555
uses: actions/upload-artifact@v3
5656
with:
5757
name: sbom
58-
path: bom.json
58+
path: sbom.json
59+
- name: Scan SBOM
60+
uses: anchore/scan-action@v3
61+
with:
62+
sbom: "sbom.json"
63+
output-format: table
5964

6065
bearer:
6166
name: Bearer

0 commit comments

Comments
 (0)