Commit d9b83537 authored by Tomasz Maczukin's avatar Tomasz Maczukin

Merge branch '3896-update-helper-image-base-image' into 'master'

Change helper image to servercore

See merge request !1290
parents bb93deef 24b238a3
......@@ -52,7 +52,7 @@ image: $CI_IMAGE
.windows1803: &windows1803
variables: &windows1803_variables
<<: *windows_base_variables
WINDOWS_VERSION: nanoserver1803
WINDOWS_VERSION: servercore1803
tags:
- windows-1803
- shell
......@@ -60,7 +60,7 @@ image: $CI_IMAGE
.windows1809: &windows1809
variables: &windows1809_variables
<<: *windows_base_variables
WINDOWS_VERSION: nanoserver1809
WINDOWS_VERSION: servercore1809
tags:
- windows-1809
- shell
......@@ -511,12 +511,12 @@ development docker images:
tags:
- docker
development nanoserver1803 helper docker image:
development servercore1803 helper docker image:
<<: *release_development
<<: *windows1803
extends: .build_windows_docker_images
development nanoserver1809 helper docker image:
development servercore1809 helper docker image:
<<: *release_development
<<: *windows1809
extends: .build_windows_docker_images
......@@ -542,7 +542,7 @@ bleeding edge docker images:
name: bleeding_edge/docker_images
url: https://hub.docker.com/r/gitlab/gitlab-runner/tags/
bleeding edge nanoserver1803 docker images:
bleeding edge servercore1803 docker images:
<<: *release_bleeding_edge
<<: *windows1803
extends: .build_windows_docker_images
......@@ -553,7 +553,7 @@ bleeding edge nanoserver1803 docker images:
name: bleeding_edge/docker_images/windows1803
url: https://hub.docker.com/r/gitlab/gitlab-runner/tags/
bleeding edge nanoserver1809 docker images:
bleeding edge servercore1809 docker images:
<<: *release_bleeding_edge
<<: *windows1809
extends: .build_windows_docker_images
......@@ -585,7 +585,7 @@ stable docker images:
name: stable/docker_images
url: https://hub.docker.com/r/gitlab/gitlab-runner/tags/
stable nanoserver1803 docker images:
stable servercore1803 docker images:
<<: *release_stable
<<: *windows1803
extends: .build_windows_docker_images
......@@ -596,7 +596,7 @@ stable nanoserver1803 docker images:
name: stable/docker_images/windows1803
url: https://hub.docker.com/r/gitlab/gitlab-runner/tags/
stable nanoserver1809 docker images:
stable servercore1809 docker images:
<<: *release_stable
<<: *windows1809
extends: .build_windows_docker_images
......
......@@ -22,13 +22,10 @@ RUN powershell -File .\checksum.ps1 -TargetFile git-lfs.zip -ExpectedHash ${Env:
RUN Expand-Archive -Path git.zip -DestinationPath git
RUN Expand-Archive -Path git-lfs.zip -DestinationPath git-lfs
FROM mcr.microsoft.com/windows/nanoserver:1803
FROM mcr.microsoft.com/windows/servercore:1803
USER ContainerAdministrator
# https://github.com/StefanScherer/dockerfiles-windows/tree/master/golang-issue-21867
COPY --from=builder ["/windows/system32/netapi32.dll", "/windows/system32/netapi32.dll"]
COPY --from=builder ["git", "C:\\Program Files\\git"]
COPY --from=builder ["git-lfs", "C:\\Program Files\\git-lfs"]
RUN setx PATH "%PATH%;C:\Program Files\git\cmd;C:\Program Files\git-lfs;C:\Program Files\gitlab-runner-helper" /M
......
......@@ -22,13 +22,10 @@ RUN powershell -File .\checksum.ps1 -TargetFile git-lfs.zip -ExpectedHash ${Env:
RUN Expand-Archive -Path git.zip -DestinationPath git
RUN Expand-Archive -Path git-lfs.zip -DestinationPath git-lfs
FROM mcr.microsoft.com/windows/nanoserver:1809_amd64
FROM mcr.microsoft.com/windows/servercore:1809_amd64
USER ContainerAdministrator
# https://github.com/StefanScherer/dockerfiles-windows/tree/master/golang-issue-21867
COPY --from=builder ["/windows/system32/netapi32.dll", "/windows/system32/netapi32.dll"]
COPY --from=builder ["git", "C:\\Program Files\\git"]
COPY --from=builder ["git-lfs", "C:\\Program Files\\git-lfs"]
RUN setx PATH "%PATH%;C:\Program Files\git\cmd;C:\Program Files\git-lfs;C:\Program Files\gitlab-runner-helper" /M
......
......@@ -12,15 +12,15 @@ const (
windows1809 = "1809"
windows1803 = "1803"
nanoserver1809 = "nanoserver1809"
nanoserver1803 = "nanoserver1803"
baseImage1809 = "servercore1809"
baseImage1803 = "servercore1803"
windowsSupportedArchitecture = "x86_64"
)
var supportedOSVersions = map[string]string{
windows1803: nanoserver1803,
windows1809: nanoserver1809,
windows1803: baseImage1803,
windows1809: baseImage1809,
}
var ErrUnsupportedOSVersion = errors.New("could not determine windows version")
......
......@@ -17,17 +17,17 @@ func Test_windowsInfo_Tag(t *testing.T) {
}{
{
operatingSystem: "Windows Server 2019 Datacenter Evaluation Version 1809 (OS Build 17763.316)",
expectedVersion: fmt.Sprintf("%s-%s-%s", "x86_64", revision, nanoserver1809),
expectedVersion: fmt.Sprintf("%s-%s-%s", "x86_64", revision, baseImage1809),
expectedErr: nil,
},
{
operatingSystem: "Windows Server Datacenter Version 1809 (OS Build 1803.590)",
expectedVersion: fmt.Sprintf("%s-%s-%s", "x86_64", revision, nanoserver1809),
expectedVersion: fmt.Sprintf("%s-%s-%s", "x86_64", revision, baseImage1809),
expectedErr: nil,
},
{
operatingSystem: "Windows Server Datacenter Version 1803 (OS Build 17134.590)",
expectedVersion: fmt.Sprintf("%s-%s-%s", "x86_64", revision, nanoserver1803),
expectedVersion: fmt.Sprintf("%s-%s-%s", "x86_64", revision, baseImage1803),
expectedErr: nil,
},
{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment