From 07b9d254dfe47ea4630dbf4efbc957d56379a057 Mon Sep 17 00:00:00 2001 From: Grzegorz Graczyk Date: Wed, 21 Oct 2015 14:27:34 +0200 Subject: [PATCH] fixes #8 --- main.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/main.go b/main.go index 0782478..8b0bb5b 100644 --- a/main.go +++ b/main.go @@ -38,7 +38,7 @@ func main() { // in case someone uses the shorthand repository name // with a custom registry, we should concatinate so that // we have the fully qualified image name. - if strings.Count(vargs.Repo, "/") == 1 && len(vargs.Registry) != 0 { + if strings.Count(vargs.Repo, "/") <= 1 && len(vargs.Registry) != 0 && !strings.HasPrefix(vargs.Repo, vargs.Registry) { vargs.Repo = fmt.Sprintf("%s/%s", vargs.Registry, vargs.Repo) }