mirror of
https://github.com/project-zot/zot.git
synced 2026-06-17 04:48:26 +08:00
list all images that have all layers of the base image included (2) (#813)
* list all images that are base images for the given image + zli command Signed-off-by: Lisca Ana-Roberta <ana.kagome@yahoo.com> * Fix a failing test The test expected the image size to be the size of the layer, not the manifest+config+layer Signed-off-by: Andrei Aaron <andaaron@cisco.com> Signed-off-by: Lisca Ana-Roberta <ana.kagome@yahoo.com> Signed-off-by: Andrei Aaron <andaaron@cisco.com> Co-authored-by: Lisca Ana-Roberta <ana.kagome@yahoo.com>
This commit is contained in:
@@ -24,6 +24,15 @@ type OciLayoutUtilsMock struct {
|
||||
GetExpandedRepoInfoFn func(name string) (common.RepoInfo, error)
|
||||
GetImageConfigInfoFn func(repo string, manifestDigest godigest.Digest) (ispec.Image, error)
|
||||
CheckManifestSignatureFn func(name string, digest godigest.Digest) bool
|
||||
GetRepositoriesFn func() ([]string, error)
|
||||
}
|
||||
|
||||
func (olum OciLayoutUtilsMock) GetRepositories() ([]string, error) {
|
||||
if olum.GetImageManifestsFn != nil {
|
||||
return olum.GetRepositoriesFn()
|
||||
}
|
||||
|
||||
return []string{}, nil
|
||||
}
|
||||
|
||||
func (olum OciLayoutUtilsMock) GetImageManifests(image string) ([]ispec.Descriptor, error) {
|
||||
|
||||
Reference in New Issue
Block a user