Repository navigation
feat(cli): Allow to load materials from external sources - #1861
Merged
Merged
Conversation
Signed-off-by: Javier Rodriguez <javier@chainloop.dev>
Signed-off-by: Javier Rodriguez <javier@chainloop.dev>
migmartri
reviewed
Feb 27, 2025
Signed-off-by: Javier Rodriguez <javier@chainloop.dev>
jiparis
reviewed
Feb 27, 2025
migmartri
approved these changes
Feb 27, 2025
Signed-off-by: Javier Rodriguez <javier@chainloop.dev>
migmartri
approved these changes
Feb 27, 2025
migmartri
left a comment
Member
There was a problem hiding this comment.
Great!
We might want to also add an example that says that you if you provide an http url the content will be downloaded first.
Signed-off-by: Javier Rodriguez <javier@chainloop.dev>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
This patch enhances the
attestation addcommand by allowing it to accept HTTP(S) URLs. When a URL is provided, the CLI downloads the file and uses it for attestation, eliminating the need for users to have the file locally. Internally, the CLI stores the downloaded file in a temporary directory, preserving its base name for material verification before pushing it to the configured CAS.The existing behavior of loading files from the local file system remains unchanged.
A few examples:
Loading a GitLab Security Report from the file system:
Loading another material from an URL:
Special cases such as container images remain the same as before: