-
-
Notifications
You must be signed in to change notification settings - Fork 4
Implement intermediate SBOM generation and SPDX serialization #63
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Implement intermediate SBOM generation and SPDX serialization #63
Conversation
@@ -0,0 +1,23 @@ | |||
load("@rules_go//go:def.bzl", "go_binary", "go_library") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd put this into //sbom/spdx/generator
. I'd like to keep //lib/supplychain-go
light and not pull in lots of dependencies for all kinds of sbom formats
|
||
go_library( | ||
name = "supply-chain-go", | ||
name = "supplychain-go", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Mind splitting this one out into its own PR?
Also, we should probably add an alias for the old name
return rule( | ||
_sbom_impl, | ||
attrs = { | ||
"target": attr.label(aspects = [gathering_aspect], doc="The target for which to generate an SBOM."), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
From internal experience, this should be label_list
return gather_metadata_info_common( | ||
target, | ||
ctx, | ||
want_providers = [PackageAttributeInfo, PackageMetadataInfo, LicenseKindInfo], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What do we need AttributeInfo
and LicenseKindInfo
for? They are referenced in the JSON file
This change allows a user to create an intermediate sbom format via the sbom target that can later be consumed into a serialized format like SPDX by specialized rules.