Skip to content

Instantly share code, notes, and snippets.

@colinbut
Created February 6, 2022 10:30
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save colinbut/75995e911806cd5c51a811c906d2400a to your computer and use it in GitHub Desktop.
Save colinbut/75995e911806cd5c51a811c906d2400a to your computer and use it in GitHub Desktop.
stage("Generate Software Bill of Materials (sbom) with Syft"){
steps{
sh '''
curl -sSfL https://raw.githubusercontent.com/anchore/syft/main/install.sh | sh -s -- -b /usr/local/bin
syft app:${BUILD_NUMBER} --scope all-layers -o json > sbom-${BUILD_NUMBER}.json
syft app:${BUILD_NUMBER} --scope all-layers -o table > sbom-${BUILD_NUMBER}.txt
'''
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment