docs: ADR-0002: import subcommand #102
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
2. Import subcommand
Date: 2024-07-09
Status
Accepted
Context
There is currently no capability of importing SBOM or protobom data from either
stdinor local filesystem path(s).Decision
Introduce an
importcommand that will accept one of the following options as input:stdinby using the argument--is howkubectlaccepts stdin (see kubectl examples)--input,--file,--path, etc.The supported input types will be:
Document(such as the serialized protocol buffer storage format used by the ProtobomFileSystemBackend)The
fetchcommand will now be able to simply fetch raw bytes data and leverage the newimportlogic to store.Consequences
Integration between CLI tools
Promotes integration with other CLI tools by accepting their piped output.
For example, this could enable usage patterns such as:
curl --silent --url https://acme.example.com/sbom.cdx.json | bomctl importInput flexibility
Presents additional input options for users that may feel more natural.
Feature parity
Adds a counterpart to the
exportcommand for feature parity and completeness.References