-
Notifications
You must be signed in to change notification settings - Fork 5.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add environment variable to force windows parsing style of volume paths #5560
Conversation
cc @StefanScherer if you can give this a whirl, that'd be awesome! |
Signed-off-by: Joffrey F <[email protected]>
495ed45
to
2fbec60
Compare
Thanks. I compiled the Darwin binary, but I still see this error: Without any environment variable:
With
I also tried a Windows build from inside the Win2016 VM, but I also see error, both with short and long variant and without and with the environment variable set.
I think this should be solved without additional environment variables that the user has to define and know of. Instead docker-compose should recognise the Docker server platform. |
Have you tried using single backslashes? In my tests the double slashes weren't necessary. The error you get from the server seems to indicate that as well.
I considered it, but there are some architectural limitations that make this complicated. Specifically, it would mean |
Woot woot!
Oh and it works with docker-compose 1.18.0 as well
Will add some comments in #5371 |
So it already works without setting an environment variable with 1.18.0, but with the extended syntax and natural looking single backslashes. 🎉 |
I often use |
Short syntax should work with the flag and single slashes. |
@shin- It looks like this PR may have broken some mounts when used under Docker for Windows. Have a look at docker/for-win#1829 for details. |
@jimgolfgti This change was made in 1.19.0, which was already included in Docker For Windows 18.02.0-ce. As a result, it's probably not the cause of the issue. That said, I'll look through the changes we made in 1.20 and see if there's anything else that could have caused the issue. |
Fixes #5371
Users can set
COMPOSE_FORCE_WINDOWS_HOST=1
to parse volumes and normalize paths as if working from a WIndows host, even if Compose is running on a UNIX system.