I finally managed to get Server-Media-Foundation installed and working in Windows Server 2016 Docker container
You can find a Dockerfile and the script used to patch up the .mum files on here on GitHub
Some of the solutions I did find that had worked (see references below), was patching selected mum files, but I realized two things, depending on the version/build of your base image the require set of files to patch might vary. And secondly, you will not be able to install any other component that requires a restart in the container anyway, so I just went a head with a script that removes any restart requirements. This can possibly work for other windows server feature installs as well. You mileage might vary...
Some gotchas that I encountered.
docker pull/buildwill use image matching your build machine OS build number if base image is microsoft/aspnet
Although files and registry entries appears to be installed correctly on 1709, MF is not able to find any Media Foundation Transforms. I have been using the MFTEnum tool from Matthew van Eerde's blog to validate the validity of the install. It is possible that if you don't need the Media Foundation Transforms in your scenario that it could still work on 1709, I just don't know.
Honestly I don't know why it doesn't work on 1709, I've been looking at c:\windows\Logs\CBS\CBS.log and comparing with 2016 but nothing has stood out, and no specific errors reported in 1709 that is different from 2016. Anyway, for me it is enough it works on 2016.
I was trying to build my docker images based on microsoft/aspnet images, and I couldn't make it work. It turns out that if you are using a windows 10 machine to build your Docker images, and your windows 10 are on build 16299, be careful as it will use the microsoft/aspnet images that matches you machine's build number, i.e. on my Windows 10 it is 16299 which matches up with Windows Server 1709. If you build straight from microsoft/windowsservercore it defaults to WS2016 so then it is ok. I figured this out after trying to build the same Dockerfile on a Windows Server 2016 and it works, turns out then it pulled a different microsoft/aspnet image that matched my server build number 14393 instead. I did not yet try to build the Docker image on a 1709 server, but I suspect it is the same result.
To note is that I was not able to get it to work on 1709, on 1709 you can run
Install-WindowsFeature Server-Media-Foundationand it reports success, and no need to reboot, but it does NOT work.
I also tried building a 1709 container on a 1709 server, but same result.