Get OS dependent pre build image for docker executor
Description
After #3755 (closed) we publish two kinds of helper images. 1. Linux Based, 2. Windows Based. Inside of getPrebuiltImage
we pull this image. Since we have two type of images now we have to detect the runtime of the job and decide which pre build image to use.
Proposal
- We have
getArchitecture
which just needs extending to support windows - Detect windows version, assuming powershell is installed on all systems we can use
(Get-Item "HKLM:SOFTWARE\Microsoft\Windows NT\CurrentVersion").GetValue('ReleaseID')
- this will not support remote docker executors. - Disable prelaoding image from local file system https://gitlab.com/gitlab-org/gitlab-runner/blob/fe27878158855ba81313273f7f83bf86063f05b0/executors/docker/executor_docker.go#L316-326 for windows
Links to related issues and merge requests / references
Blocked by: #3755 (closed)
Epic: &535 (closed)
Edited by Steve Xuereb