mirror of
https://github.com/mudler/luet.git
synced 2025-09-01 23:37:07 +00:00
Support content trust images and pull with authentication
Contact the notary server if ```--verify``` is specified (or `verify: true` is enabled on the repo config) and verify if the image is signed, use the returned value to pull the verified image.
This commit is contained in:
@@ -31,6 +31,7 @@ func (c *Client) Pull(image string) (*ListedImage, error) {
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
// Parse the image name and tag.
|
||||
named, err := reference.ParseNormalizedNamed(image)
|
||||
if err != nil {
|
||||
@@ -114,7 +115,6 @@ func (c *Client) Pull(image string) (*ListedImage, error) {
|
||||
if _, err := e.Export(ctx, exporter.Source{Ref: ref}); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
// Get the image.
|
||||
img, err := opt.ImageStore.Get(ctx, image)
|
||||
if err != nil {
|
||||
|
Reference in New Issue
Block a user