shipyard
shipyard copied to clipboard
yard Docker mounts for ~/.shipyard break in WSL 1
Hi,
I noticed when running yard from within WSL 1 it tells Docker to mount /files into the consul-k8s-tools container using, obviously, the Linux file-system perspective of ~/.shipyard.
As WSL 1 does not support running Docker its daemon is running on the Windows side where it cannot see those folders, while from within WSL the docker client commands the daemon via Docker's TCP socket.
I currently see two options getting around this:
1 Use a Path Convention to Enable Docker to Mount WSL Files from Windows
There is a way to access WSL files from Windows but it seems to rely on UNC paths like: \\wsl$\[distro_name]
See: https://devblogs.microsoft.com/commandline/whats-new-for-wsl-in-windows-10-version-1903/
However when playing around with it I did not get it to work immediately. Maybe there is some prefixing or quoting of the UNC path necessary or Docker simply does not support this kind of mount.
2 Simply Install .shipyard into the Windows User Home and ln -s it Back to WSL
This to me seems like a more stable approach. Basically install into /mnt/c/USERNAME/.shipyard and then ln -s /mnt/c/USERNAME/.shipyard ~/.shipyard. Finally make yard generate mounts paths like //C/Users/USERNAME/.shipyard.
Cheers
Thanks so much @paxbit, I am going to try and get hold of a license for Windows so I can debug and fix this.