Official-images: windowsservercore variants support

Created on 1 Dec 2020  ·  5Comments  ·  Source: docker-library/official-images

Hello,

A user opened a PR on our repo to add some windowsservercore variants (2004, 1909, 1904, 1809, ltsc2019)

https://github.com/traefik/traefik-library-image/pull/2

I checked the official-images repo, and I only see 2 variants used: windowsservercore-ltsc2016 and windowsservercore-1809

Is it possible to use those variants inside the official Docker images build system?

Most helpful comment

That’s a painpoint on Windows. With a 1809 host you cannot build images with newer base images.

A Windows Server version 2004 would be required to build all variants. Hard to get such a machine due to the licensing. There are Azure VM images provided by MSFT, but probably not easy to use in the build infrastructure.

For my own Windows images that only require nanoserver, I used a different approach. I „rebase“ the application layers on top of newer base layers with a small tool. Absolute experimental and not recommended to provide official images, otherwise you really know what you‘re doing 😅

I know that portainer uses my tool as well, eg. https://hub.docker.com/layers/portainer/portainer-ce/2.0.0/images/sha256-8e1b979bc8e80127196304ffe6e5ae5b3d333887b1bde588d06615cef3b7c52a?context=explore gas variants 1809, 1903, 1909, and 2004.

My dockerfiles-windows github repo also uses this technique for a few images. But traefik needs one additional dll due to the golang bug. It‘s all very complicated.

So the TL/DR would be that it‘s not possible for official images.
But don‘t hesitate to ping me if you want to know more and go that route. 😊

All 5 comments

We only have one Windows VM for builds and it is running LTSC 2019 (aka 1809). So, we cannot build anything other than ltsc2016 and 1809 since there hasn't been a newer LTSC. :disappointed:

Related: https://github.com/docker-library/golang/pull/289

https://winreleaseinfoprod.blob.core.windows.net/winreleaseinfoprod/en-US.html

maybe @StefanScherer can help here?

It's more of a fundamental Windows issue for us -- the semi-annual channel
doesn't support in-place upgrades, so our best workaround idea has been to
run Windows 10 instead of Server, but that's not well-supported in cloud
environments.

That’s a painpoint on Windows. With a 1809 host you cannot build images with newer base images.

A Windows Server version 2004 would be required to build all variants. Hard to get such a machine due to the licensing. There are Azure VM images provided by MSFT, but probably not easy to use in the build infrastructure.

For my own Windows images that only require nanoserver, I used a different approach. I „rebase“ the application layers on top of newer base layers with a small tool. Absolute experimental and not recommended to provide official images, otherwise you really know what you‘re doing 😅

I know that portainer uses my tool as well, eg. https://hub.docker.com/layers/portainer/portainer-ce/2.0.0/images/sha256-8e1b979bc8e80127196304ffe6e5ae5b3d333887b1bde588d06615cef3b7c52a?context=explore gas variants 1809, 1903, 1909, and 2004.

My dockerfiles-windows github repo also uses this technique for a few images. But traefik needs one additional dll due to the golang bug. It‘s all very complicated.

So the TL/DR would be that it‘s not possible for official images.
But don‘t hesitate to ping me if you want to know more and go that route. 😊

Ugly. Very ugly... 😐 Then I'll just use my own traefik images and hope for the best...

Was this page helpful?
0 / 5 - 0 ratings

Related issues

bebehei picture bebehei  ·  8Comments

federico-razzoli picture federico-razzoli  ·  3Comments

yosifkit picture yosifkit  ·  7Comments

davivcgarcia picture davivcgarcia  ·  4Comments

andersla picture andersla  ·  4Comments