From 3597d752817c8c81ace2310d6930fb15db47cf7c Mon Sep 17 00:00:00 2001 From: Daniel Hiltgen Date: Mon, 10 Sep 2018 15:08:24 -0700 Subject: [PATCH] Prefix engine repo with store The official access point for the Q3 engine images will be prefixed by store. Signed-off-by: Daniel Hiltgen Signed-off-by: Sebastiaan van Stijn --- cli/command/engine/activate.go | 2 +- cli/command/engine/auth.go | 2 +- cli/command/engine/init.go | 2 +- cli/command/engine/update_test.go | 2 +- internal/containerizedengine/update_test.go | 4 ++-- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/cli/command/engine/activate.go b/cli/command/engine/activate.go index 270daff720..1e8b745929 100644 --- a/cli/command/engine/activate.go +++ b/cli/command/engine/activate.go @@ -56,7 +56,7 @@ https://hub.docker.com/ then specify the file with the '--license' flag. flags.StringVar(&options.licenseFile, "license", "", "License File") flags.StringVar(&options.version, "version", "", "Specify engine version (default is to use currently running version)") - flags.StringVar(&options.registryPrefix, "registry-prefix", "docker.io/docker", "Override the default location where engine images are pulled") + flags.StringVar(&options.registryPrefix, "registry-prefix", "docker.io/store/docker", "Override the default location where engine images are pulled") flags.StringVar(&options.image, "engine-image", clitypes.EnterpriseEngineImage, "Specify engine image") flags.StringVar(&options.format, "format", "", "Pretty-print licenses using a Go template") flags.BoolVar(&options.displayOnly, "display-only", false, "only display the available licenses and exit") diff --git a/cli/command/engine/auth.go b/cli/command/engine/auth.go index fdf04594a8..431a27f8f7 100644 --- a/cli/command/engine/auth.go +++ b/cli/command/engine/auth.go @@ -13,7 +13,7 @@ import ( func getRegistryAuth(cli command.Cli, registryPrefix string) (*types.AuthConfig, error) { if registryPrefix == "" { - registryPrefix = "docker.io/docker" + registryPrefix = "docker.io/store/docker" } distributionRef, err := reference.ParseNormalizedNamed(registryPrefix) if err != nil { diff --git a/cli/command/engine/init.go b/cli/command/engine/init.go index 9d1ff3e34e..a2d68b8fc0 100644 --- a/cli/command/engine/init.go +++ b/cli/command/engine/init.go @@ -35,7 +35,7 @@ file on the host and may be pre-created before running the 'init' command. flags := cmd.Flags() flags.StringVar(&options.EngineVersion, "version", cli.Version, "Specify engine version") flags.StringVar(&options.EngineImage, "engine-image", clitypes.CommunityEngineImage, "Specify engine image") - flags.StringVar(&options.RegistryPrefix, "registry-prefix", "docker.io/docker", "Override the default location where engine images are pulled") + flags.StringVar(&options.RegistryPrefix, "registry-prefix", "docker.io/store/docker", "Override the default location where engine images are pulled") flags.StringVar(&options.ConfigFile, "config-file", "/etc/docker/daemon.json", "Specify the location of the daemon configuration file on the host") flags.StringVar(&options.sockPath, "containerd", "", "override default location of containerd endpoint") diff --git a/cli/command/engine/update_test.go b/cli/command/engine/update_test.go index a609113296..a17f5b5b21 100644 --- a/cli/command/engine/update_test.go +++ b/cli/command/engine/update_test.go @@ -28,7 +28,7 @@ func TestUpdateHappy(t *testing.T) { }, ) cmd := newUpdateCommand(testCli) - cmd.Flags().Set("registry-prefix", "docker.io/docker") + cmd.Flags().Set("registry-prefix", "docker.io/store/docker") cmd.Flags().Set("version", "someversion") err := cmd.Execute() assert.NilError(t, err) diff --git a/internal/containerizedengine/update_test.go b/internal/containerizedengine/update_test.go index cb1e06dd68..cc2c7b4d76 100644 --- a/internal/containerizedengine/update_test.go +++ b/internal/containerizedengine/update_test.go @@ -46,7 +46,7 @@ func TestGetCurrentEngineVersionEnterpriseHappy(t *testing.T) { ctx := context.Background() image := &fakeImage{ nameFunc: func() string { - return "docker.io/docker/" + clitypes.EnterpriseEngineImage + ":engineversion" + return "docker.io/store/docker/" + clitypes.EnterpriseEngineImage + ":engineversion" }, } container := &fakeContainer{ @@ -66,7 +66,7 @@ func TestGetCurrentEngineVersionEnterpriseHappy(t *testing.T) { assert.NilError(t, err) assert.Equal(t, opts.EngineImage, clitypes.EnterpriseEngineImage) assert.Equal(t, opts.EngineVersion, "engineversion") - assert.Equal(t, opts.RegistryPrefix, "docker.io/docker") + assert.Equal(t, opts.RegistryPrefix, "docker.io/store/docker") } func TestGetCurrentEngineVersionNoEngine(t *testing.T) {