Support for cross platform volume mounting in WSL
WSL has been great for dev so far. The first immersion breaker has been a big one, probably more because it's taken this long for something to happen.
So docker has been running great, making a nice one that uses multi stages took a while (Inventorious docker yo!). But I got almost all the way there, right up until volumes. I deep dived into learning about all the different kinds of volumes and hitting weird walls - like a volume mounting and zeroing out the contents where it goes. Strangely enough SO and other sites were pointing that my config was right. Went further.
I found it in the end - Host files on a volume need to be referred to by the windows mount. For example: docker container run -v $PWD/data:/usr/src/app/data somecontainer with the nice $PWD shorthand needs to become the cross compatability breaking: docker container run -v /c/Users/Win10user/Documents/Project/data:/usr/src/app/data somecontainer
This is because although I'm firing commands inside WSL, when the docker hub is invoked, that is in windows land. It doesn't understand $PWD , and even if you used the windows version of $PWD (CD , no parameters), The current working directory is lost. This affects most docker-compose.yml files that are around, as they tend to depend on non user specific paths for the volumes.
Ideally, I would like windows to at least support some form of relative directory structure ($PWD), but maybe with the coming 1903 9P update, it could pass that command right back in and let WSL interpret it correctly anyway?