summaryrefslogtreecommitdiff
path: root/pkg/domain/infra/abi/images.go
diff options
context:
space:
mode:
authorValentin Rothberg <rothberg@redhat.com>2021-05-18 10:05:03 +0200
committerValentin Rothberg <rothberg@redhat.com>2021-05-20 10:21:27 +0200
commit898a8ad28514f90e13b05707a0ead148caa33541 (patch)
tree5992a9a2a39e17d335e8f468aa4f546c2a18c91c /pkg/domain/infra/abi/images.go
parent8bc39f4a90a658e92305369cc2628e2a65874506 (diff)
downloadpodman-898a8ad28514f90e13b05707a0ead148caa33541.tar.gz
podman-898a8ad28514f90e13b05707a0ead148caa33541.tar.bz2
podman-898a8ad28514f90e13b05707a0ead148caa33541.zip
update c/common
Update containers common to the latest HEAD. Some bug fixes in libimage forced us to have a clearer separation between ordinary images and manifest lists. Hence, when looking up manifest lists without recursing into any of their instances, we need to use `LookupManifestList()`. Also account for some other changes in c/common (e.g., the changed order in the security labels). Further vendor the latest HEAD from Buildah which is required to get the bud tests to pass. Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
Diffstat (limited to 'pkg/domain/infra/abi/images.go')
-rw-r--r--pkg/domain/infra/abi/images.go9
1 files changed, 3 insertions, 6 deletions
diff --git a/pkg/domain/infra/abi/images.go b/pkg/domain/infra/abi/images.go
index 79e815490..083566201 100644
--- a/pkg/domain/infra/abi/images.go
+++ b/pkg/domain/infra/abi/images.go
@@ -313,12 +313,9 @@ func (ir *ImageEngine) Push(ctx context.Context, source string, destination stri
// list but could not find a matching image instance in the local
// containers storage. In that case, fall back and attempt to push the
// (entire) manifest.
- if errors.Cause(pushError) == storage.ErrImageUnknown {
- // Image might be a manifest list so attempt a manifest push
- _, manifestErr := ir.ManifestPush(ctx, source, destination, options)
- if manifestErr == nil {
- return nil
- }
+ if _, err := ir.Libpod.LibimageRuntime().LookupManifestList(source); err == nil {
+ _, err := ir.ManifestPush(ctx, source, destination, options)
+ return err
}
return pushError
}