mirror of
https://github.com/containers/skopeo.git
synced 2025-06-29 08:07:37 +00:00
drop the Registry field in output - images are not fully qualified
Signed-off-by: Antonio Murdaca <runcom@redhat.com>
This commit is contained in:
parent
6ea444ad5a
commit
e1291313aa
@ -54,7 +54,6 @@ TODO
|
||||
- show repo tags via flag or when reference isn't tagged or digested
|
||||
- add tests (integration with deployed registries in container - Docker-like)
|
||||
- get rid of Docker (meaning make this work w/o needing Docker installed)
|
||||
- drop the `Registry` field in the response because of the point above :)
|
||||
|
||||
NOT TODO
|
||||
-
|
||||
|
@ -52,7 +52,6 @@ type imageInspect struct {
|
||||
Config *containerTypes.Config
|
||||
Architecture string
|
||||
Os string
|
||||
Registry string
|
||||
}
|
||||
|
||||
func validateName(name string) error {
|
||||
@ -241,7 +240,7 @@ func validateRepoName(name string) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func makeImageInspect(img *image.Image, index, tag string, dgst digest.Digest, tagList []string) *imageInspect {
|
||||
func makeImageInspect(img *image.Image, tag string, dgst digest.Digest, tagList []string) *imageInspect {
|
||||
var digest string
|
||||
if err := dgst.Validate(); err == nil {
|
||||
digest = dgst.String()
|
||||
@ -258,7 +257,6 @@ func makeImageInspect(img *image.Image, index, tag string, dgst digest.Digest, t
|
||||
Config: img.Config,
|
||||
Architecture: img.Architecture,
|
||||
Os: img.OS,
|
||||
Registry: index,
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -145,7 +145,7 @@ func (mf *v1ManifestFetcher) fetchWithSession(ctx context.Context, askedTag stri
|
||||
return nil, fmt.Errorf("No such image %s:%s", mf.repoInfo.FullName(), askedTag)
|
||||
}
|
||||
|
||||
return makeImageInspect(pulledImg, mf.repoInfo.Index.Name, askedTag, "", tagList), nil
|
||||
return makeImageInspect(pulledImg, askedTag, "", tagList), nil
|
||||
}
|
||||
|
||||
func (mf *v1ManifestFetcher) pullImageJSON(imgID, endpoint string, token []string) (*image.Image, error) {
|
||||
|
@ -154,7 +154,7 @@ func (mf *v2ManifestFetcher) fetchWithRepository(ctx context.Context, ref refere
|
||||
//ref = reference.WithDefaultTag(ref)
|
||||
//}
|
||||
//_ = showTags
|
||||
return makeImageInspect(image, mf.repoInfo.Index.Name, tag, manifestDigest, tagList), nil
|
||||
return makeImageInspect(image, tag, manifestDigest, tagList), nil
|
||||
}
|
||||
|
||||
func (mf *v2ManifestFetcher) pullSchema1(ctx context.Context, ref reference.Named, unverifiedManifest *schema1.SignedManifest) (img *image.Image, manifestDigest digest.Digest, err error) {
|
||||
|
Loading…
Reference in New Issue
Block a user