From 72a9000fcfa2ec5a2c4a29fb62a17c34e6dd186f Mon Sep 17 00:00:00 2001 From: Jessica Frazelle Date: Wed, 4 Feb 2015 15:06:34 -0800 Subject: [PATCH] Removes the feature to pull all image aliases. It didn't work on v2 anyways. And an image with a lot of aliases was slow to fetch. Docker-DCO-1.1-Signed-off-by: Jessie Frazelle (github: jfrazelle) --- docs/sources/reference/commandline/cli.md | 3 +-- graph/pull.go | 4 +--- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/docs/sources/reference/commandline/cli.md b/docs/sources/reference/commandline/cli.md index 17b378ecfb..962bcdb29a 100644 --- a/docs/sources/reference/commandline/cli.md +++ b/docs/sources/reference/commandline/cli.md @@ -1474,8 +1474,7 @@ To download a particular image, or set of images (i.e., a repository), use `docker pull`: $ sudo docker pull debian - # will pull the debian:latest image, its intermediate layers - # and any aliases of the same id + # will pull the debian:latest image and its intermediate layers $ sudo docker pull debian:testing # will pull the image named debian:testing and any intermediate # layers it is based on. diff --git a/graph/pull.go b/graph/pull.go index fd6170b571..1ac6f2cdaa 100644 --- a/graph/pull.go +++ b/graph/pull.go @@ -132,7 +132,6 @@ func (s *TagStore) pullRepository(r *registry.Session, out io.Writer, repoInfo * log.Debugf("Registering tags") // If no tag has been specified, pull them all - var imageId string if askedTag == "" { for tag, id := range tagsList { repoData.ImgList[id].Tag = tag @@ -143,7 +142,6 @@ func (s *TagStore) pullRepository(r *registry.Session, out io.Writer, repoInfo * if !exists { return fmt.Errorf("Tag %s not found in repository %s", askedTag, repoInfo.CanonicalName) } - imageId = id repoData.ImgList[id].Tag = askedTag } @@ -247,7 +245,7 @@ func (s *TagStore) pullRepository(r *registry.Session, out io.Writer, repoInfo * } for tag, id := range tagsList { - if askedTag != "" && id != imageId { + if askedTag != "" && tag != askedTag { continue } if err := s.Set(repoInfo.LocalName, tag, id, true); err != nil {