Create a windows 10 image for use as a docker container

I'm trying to create a Windows 10 image in order to dockerize an existing legacy application. For very good reasons, the base image has to be Windows 10 not Windows Server. How do I go about doing this?

What I had in mind was:

1) Create my vanilla Windows install as a Hyper-V machine

2) Install the application onto it

3) Shutdown this VM

4) Convert the resulting VHDX to a Windows Image (WIM) file

5) Somehow use this as the base image for docker

Am I on the right path?

No, this won't work.

Windows Containers (this is the same as Docker containers on Linux) basically contain the "user-space" part of windows, but share the single underlying windows server kernel.

I find a convenient way to think of it is that each container is kind of like a separate isolated user account in windows. You can have multiple user accounts, and they each have their own private set of files, and are each walled off from eachother, but they are still tied directly to the underlying OS, and each all running on the same shared kernel.

This is great as with a single shared kernel we don't need hardware virtualization at the CPU or memory level so things can be much more efficient.

Following that design however, the Windows 10 UI and all that stuff aren't designed to work with the Windows Server 2016 kernel. They might work by co-incidence but it's not likely.

Also, you can't just take a VHD/WIM or other kind of image and say "that's my container". You've got to start with a "base image" which is effectively a representation of your main OS, and then apply changes as needed. I can't imagine trying to figure out the set of changes needed to take a base windows server, and turn it into windows 10.

Looks like someone achieved it, but the comments show not many people could reproduce:

What are your “very good reasons”?

the good reason was for it to run SAS which only runs on non-server windows unless you by the server version

The closest to Windows Containers on Windows 10 that comes to my mind is App-V.