Skip to content

Commit

Permalink
SBOM generation and inclusion (#20)
Browse files Browse the repository at this point in the history
* Add script for generating SBOM

* Add in spdx.json file to python builds
  • Loading branch information
mbish authored Jun 21, 2023
1 parent 534b0a9 commit eacb8dd
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 0 deletions.
4 changes: 4 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,10 @@ jobs:
run: |
python -m pip install --upgrade pip
pip install setuptools wheel twine
- name: Generate SBOM
run: |
pip install cyclonedx-bom
./scripts/make-sbom.sh
- name: Build and publish
env:
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
Expand Down
1 change: 1 addition & 0 deletions MANIFEST.in
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
include requirements.txt
include spdx.json
graft tests

5 changes: 5 additions & 0 deletions scripts/make-sbom.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#!/usr/bin/env bash
cyclonedx-py --e --format json -o cyclonedx-sbom.json
wget https://github.com/CycloneDX/cyclonedx-cli/releases/download/v0.24.2/cyclonedx-linux-x64
chmod u+x cyclonedx-linux-x64
./cyclonedx-linux-x64 convert --input-format json --output-format spdxjson --input-file cyclonedx-sbom.json --output-file spdx.json

0 comments on commit eacb8dd

Please sign in to comment.