summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatej Vasek <mvasek@redhat.com>2021-05-05 21:45:29 +0200
committerMatej Vasek <mvasek@redhat.com>2021-05-05 22:03:11 +0200
commitc58feddb7bcd7f59a72e3dab3413f99e99296cce (patch)
treec2ff2c212713fbe2464ba855d5f6e9cc928ec68c
parent404bc2684edd14b20d02d8cd05ca3e6b6ee8888d (diff)
downloadpodman-c58feddb7bcd7f59a72e3dab3413f99e99296cce.tar.gz
podman-c58feddb7bcd7f59a72e3dab3413f99e99296cce.tar.bz2
podman-c58feddb7bcd7f59a72e3dab3413f99e99296cce.zip
fix: docker APIv2 `images/get`
Signed-off-by: Matej Vasek <mvasek@redhat.com>
-rw-r--r--pkg/api/handlers/compat/images.go2
-rw-r--r--test/apiv2/10-images.at1
2 files changed, 2 insertions, 1 deletions
diff --git a/pkg/api/handlers/compat/images.go b/pkg/api/handlers/compat/images.go
index 0b9367a17..0f7e0ccf5 100644
--- a/pkg/api/handlers/compat/images.go
+++ b/pkg/api/handlers/compat/images.go
@@ -466,7 +466,7 @@ func ExportImages(w http.ResponseWriter, r *http.Request) {
imageEngine := abi.ImageEngine{Libpod: runtime}
- saveOptions := entities.ImageSaveOptions{Output: tmpfile.Name()}
+ saveOptions := entities.ImageSaveOptions{Format: "docker-archive", Output: tmpfile.Name()}
if err := imageEngine.Save(r.Context(), images[0], images[1:], saveOptions); err != nil {
utils.InternalServerError(w, err)
return
diff --git a/test/apiv2/10-images.at b/test/apiv2/10-images.at
index a08393668..a6764371c 100644
--- a/test/apiv2/10-images.at
+++ b/test/apiv2/10-images.at
@@ -151,5 +151,6 @@ t DELETE libpod/images/test1:latest 200
# actual: {"cause":"no such image","message":"unable to find a name and tag match for busybox in repotags: no such image","response":500}
#
#t GET images/get?names=alpine,busybox 200 '[POSIX tar archive]'
+t GET "images/get?names=alpine" 200 '[POSIX tar archive]'
# vim: filetype=sh