Skip to content
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

Protocol Error when symlinking in the app folder on Windows #294

Open
ocdtrekkie opened this issue Mar 31, 2021 · 3 comments
Open

Protocol Error when symlinking in the app folder on Windows #294

ocdtrekkie opened this issue Mar 31, 2021 · 3 comments
Labels

Comments

@ocdtrekkie
Copy link
Collaborator

So, this particularly seems to happen if I try to work with anything Node-based, but whenever a script attempts to symlink in the directory shared with the host machine, if the host machine is a Windows box, it fails with a Protocol Error, presumably because Windows doesn't support symlinks.

I am not sure how best to solve this, but arguably everything that works in vagrant-spk should theoretically work in vagrant-spk on any platform, as that's largely the goal of it supporting multiple platforms in the first place.

@ocdtrekkie ocdtrekkie added the bug label Mar 31, 2021
@zenhack
Copy link
Collaborator

zenhack commented Mar 31, 2021

Maybe we could tweak the node stack to try to dodge this somehow, but I don't see a great way out of this in general. Note that there are also other possible pitfalls due to filesystem semantic differences: Anything that cares a lot about unix permissions and/or the executable bit is going to be thrown by being on a windows filesystem also (since it doesn't have that metadata), and Linux filesystems are case-sensitive, whereas Windows (and MacOS by default) filesystems are not -- the latter bit me once when trying to build davros.

So my general posture on this is, I'm willing to merge patches that make stuff work, but unless we ditch the shared filesystem approach there's always going to be a hazard of this kind of thing.

@ocdtrekkie
Copy link
Collaborator Author

FWIW, dodging this just for the Node stack would not have saved me last night... powerbox-http-proxy uses Node to build.

I am wondering if we should look at what tricks WSL uses, and whether or not there's anything in the Windows codebase we could tap into there... presumably symlinks work on WSL, but I think it uses the normal Windows file system still?

@ocdtrekkie
Copy link
Collaborator Author

Apparently there's ways to deal with this, that involve running VirtualBox as admin in Windows or granting the user the right to create symlinks, which is restricted, and also a VirtualBox setting to enable symlinks from guest OSes.

https://www.speich.net/articles/en/2018/12/24/virtualbox-6-how-to-enable-symlinks-in-a-linux-guest-os/
https://bealers.com/fix-virtualbox-symlinks-in-guest-share-on-windows-host/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants