Skip to content

Add all Windows OS variants to better support process isolation on Windows #8

@StefanScherer

Description

@StefanScherer

Hey Phil,

what do you think about this idea. I would love to make the mquery tool available for all Windows OS variants. Only the Windows Server 2016 variant is listed in the manifest list of the mplatform/mquery image:

$ alias mq
alias mq='docker run --rm mplatform/mquery'

$ mq mplatform/mquery
Image: mplatform/mquery
 * Manifest List: Yes
 * Supported platforms:
   - linux/amd64
   - linux/arm
   - linux/arm64
   - linux/ppc64le
   - linux/s390x
   - windows/amd64:10.0.14393.1593

Well, I normally work on my MBP, but as Windows 10 now has process isolation to run Windows containers without the Hyper-V isolation it makes sense to have Windows images for the current Windows kernel version. Only then process isolation will work and people could use the mquery tool.

The golang image is an excellent example with all four Windows variants for 2016, 1709, 1803 and now 1809.

$ mq golang
Image: golang
 * Manifest List: Yes
 * Supported platforms:
   - linux/amd64
   - linux/arm/v7
   - linux/arm64
   - linux/386
   - linux/ppc64le
   - linux/s390x
   - windows/amd64:10.0.14393.2724
   - windows/amd64:10.0.16299.904
   - windows/amd64:10.0.17134.523
   - windows/amd64:10.0.17763.253

The technical challenge is that you normally need a Windows Docker host with the same or newer kernel than the Windows base image version. TL/DR you need a Windows Server 2019 or Windows 10, version 1809 to build for the latest 1809 nanoserver image. Older versions can be built in hyperv isolation mode.

I remember we have added an AppVeyor build some time ago, at the moment AppVeyor still only has Windows Server 2016 - the oldest variant.

But as a Captain this is not an impossible way. I wrote about a tool I use to create Windows images for all four variants with just AppVeyor. https://stefanscherer.github.io/poc-build-images-for-1709-without-1709/
This would work fine for this mquery tool. mquery is just a Golang binary in a nanoserver image. In this case I found out that it's fine to "rebase" the application layer on top of different Windows nanoserver images.

I do this with a multi-arch whoami service

$ mq stefanscherer/whoami
Image: stefanscherer/whoami
 * Manifest List: Yes
 * Supported platforms:
   - linux/amd64
   - linux/arm/v6
   - linux/arm64
   - windows/amd64:10.0.14393.2551
   - windows/amd64:10.0.16299.904
   - windows/amd64:10.0.17134.523
   - windows/amd64:10.0.17763.253

The complete AppVeyor build pipeline is available in https://github.com/StefanScherer/whoami

WDYT?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions