Consider WINDOWS_BASE_IMAGE_TAG override when setting Windows base image for tests
Signed-off-by: Deep Debroy <ddebroy@docker.com>
This commit is contained in:
parent
8861376202
commit
15419d7ba0
1 changed files with 6 additions and 3 deletions
|
@ -78,10 +78,13 @@ func getPlatformDefaults(info types.Info, osType string) PlatformDefaults {
|
|||
}
|
||||
case "windows":
|
||||
baseImage := "microsoft/windowsservercore"
|
||||
if override := os.Getenv("WINDOWS_BASE_IMAGE"); override != "" {
|
||||
baseImage = override
|
||||
fmt.Println("INFO: Windows Base image is ", baseImage)
|
||||
if overrideBaseImage := os.Getenv("WINDOWS_BASE_IMAGE"); overrideBaseImage != "" {
|
||||
baseImage = overrideBaseImage
|
||||
if overrideBaseImageTag := os.Getenv("WINDOWS_BASE_IMAGE_TAG"); overrideBaseImageTag != "" {
|
||||
baseImage = baseImage + ":" + overrideBaseImageTag
|
||||
}
|
||||
}
|
||||
fmt.Println("INFO: Windows Base image is ", baseImage)
|
||||
return PlatformDefaults{
|
||||
BaseImage: baseImage,
|
||||
VolumesConfigPath: filepath.FromSlash(volumesPath),
|
||||
|
|
Loading…
Reference in a new issue