From 34fed514cdaf5ac0a8520d64274b0d83f4b8a741 Mon Sep 17 00:00:00 2001 From: John Howard Date: Wed, 20 Jul 2016 09:59:52 -0700 Subject: [PATCH] Windows: Allow nanoserver image for CLI Signed-off-by: John Howard Upstream-commit: 624e6cdbf386d0862e882db9e35d2c7caaa1b337 Component: engine --- .../engine/integration-cli/docker_test_vars.go | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/components/engine/integration-cli/docker_test_vars.go b/components/engine/integration-cli/docker_test_vars.go index e668a8700c..7da3375bb8 100644 --- a/components/engine/integration-cli/docker_test_vars.go +++ b/components/engine/integration-cli/docker_test_vars.go @@ -61,12 +61,13 @@ var ( // driver of the daemon. This is initialized in docker_utils by sending // a version call to the daemon and examining the response header. daemonStorageDriver string + + // WindowsBaseImage is the name of the base image for Windows testing + // Environment variable WINDOWS_BASE_IMAGE can override this + WindowsBaseImage = "windowsservercore" ) const ( - // WindowsBaseImage is the name of the base image for Windows testing - WindowsBaseImage = "windowsservercore" - // DefaultImage is the name of the base image for the majority of tests that // are run across suites DefaultImage = "busybox" @@ -128,4 +129,9 @@ func init() { } volumesConfigPath = dockerBasePath + "/volumes" containerStoragePath = dockerBasePath + "/containers" + + if len(os.Getenv("WINDOWS_BASE_IMAGE")) > 0 { + WindowsBaseImage = os.Getenv("WINDOWS_BASE_IMAGE") + fmt.Println("INFO: Windows Base image is ", WindowsBaseImage) + } }