Skip to content

Store sbom dependencies as jenkins artifacts #121

Store sbom dependencies as jenkins artifacts

Store sbom dependencies as jenkins artifacts #121

Workflow file for this run

---
name: TestSBOM
on:
pull_request:
branches: [master]
paths:
- ".github/workflows/testsbom.yml"
- "cyclonedx-lib/**"
# Cancel existing runs if user makes another push.
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: ${{ github.event_name == 'pull_request' }}
jobs:
test_sbom_gen:
name: gen_sbom
runs-on: ubuntu-latest
container:
image: adoptopenjdk/centos7_build_image
strategy:
fail-fast: false
steps:
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3
# Build with jdk8 to ensure TemurinGenSBOM meets min compatibility
- uses: actions/setup-java@cd89f46ac9d01407894225f350157564c9c7cee2 # v3.12.0
id: setup-java
with:
java-version: 8
distribution: 'temurin'
- name: Build TemurinGenSBOM.java
run: |
ant -noinput -buildfile cyclonedx-lib/build.xml clean
ant -noinput -buildfile cyclonedx-lib/build.xml build
- name: Run TemurinGenSBOM Unit test
run: |
ant -noinput -buildfile cyclonedx-lib/build.xml run
- uses: actions/upload-artifact@0b7f8abb1508181956e8e162db84b466c27e18ce # v3.1.2
name: Collect and Archive TemurinGenSBOM Artifacts
with:
name: testSBOM
path: cyclonedx-lib/build/testSBOM.json