diff options
author | umohnani8 <umohnani@redhat.com> | 2017-12-06 14:09:51 -0500 |
---|---|---|
committer | umohnani8 <umohnani@redhat.com> | 2017-12-11 12:07:54 -0500 |
commit | 622d5e3b9a09a41f4367d8e038621e3fcbf5c7c7 (patch) | |
tree | 2ad27b4463658539257233963ae6a9c7dc38c168 /cmd/kpod/load.go | |
parent | 12682aa475db17d99eb0cfc5efad20e1b9f3685f (diff) | |
download | podman-622d5e3b9a09a41f4367d8e038621e3fcbf5c7c7.tar.gz podman-622d5e3b9a09a41f4367d8e038621e3fcbf5c7c7.tar.bz2 podman-622d5e3b9a09a41f4367d8e038621e3fcbf5c7c7.zip |
Fix misleading print statement in kpod load
When loading an image, kpod load would print something like
"Trying to pull docker.io/library/alpine...", which is misleading
and makes it sound like its pulling it form the registry.
Fixed this by removing these print statements for kpod load
Signed-off-by: umohnani8 <umohnani@redhat.com>
Diffstat (limited to 'cmd/kpod/load.go')
-rw-r--r-- | cmd/kpod/load.go | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/cmd/kpod/load.go b/cmd/kpod/load.go index 31975fc76..d29da0c06 100644 --- a/cmd/kpod/load.go +++ b/cmd/kpod/load.go @@ -1,6 +1,7 @@ package main import ( + "fmt" "io" "io/ioutil" "os" @@ -101,16 +102,18 @@ func loadCmd(c *cli.Context) error { } src := libpod.DockerArchive + ":" + input - if err := runtime.PullImage(src, options); err != nil { + imgName, err := runtime.PullImage(src, options) + if err != nil { src = libpod.OCIArchive + ":" + input // generate full src name with specified image:tag if image != "" { src = src + ":" + image } - if err := runtime.PullImage(src, options); err != nil { + imgName, err = runtime.PullImage(src, options) + if err != nil { return errors.Wrapf(err, "error pulling %q", src) } } - + fmt.Println("Loaded image: ", imgName) return nil } |