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

bindfs: Let mount find bindfs mount helper #14302

Merged
merged 1 commit into from Apr 1, 2016

Conversation

Balletie
Copy link
Contributor

When mount is used with mount-type "fuse.bindfs", it cannot find the mount helper.

If mount can't find mount.fuse.bindfs, it executes the mount.fuse mount helper and passes fuse.bindfs as argument. Then mount.fuse tries to execute bindfs on its own, but it is not found in the PATH.

By creating a mount.fuse.bindfs link to the bindfs executable, this problem is avoided because mount will just execute the mount.fuse.bindfs mount helper without mount.fuse in the middle.

Things done:
  • Tested using sandboxing (nix-build --option build-use-chroot true or nix.useChroot on NixOS)
  • Built on platform(s)
    • NixOS
    • OS X
    • Linux
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nox --run "nox-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Fits CONTRIBUTING.md.
More

cc @lovek323, Sorry for the duplicate PR.


Please note, that points are not mandatory, but rather desired.

When mount is used with mount-type "fuse.bindfs", it cannot find the
mount helper.

If mount can't find `mount.fuse.bindfs`, it executes the `mount.fuse`
mount helper and passes `fuse.bindfs` as argument. Then `mount.fuse`
tries to execute `bindfs` on its own, but it is not found in the PATH.

By creating a `mount.fuse.bindfs` link to the `bindfs` executable, this
problem is avoided because `mount` will just execute the
`mount.fuse.bindfs` mount helper without `mount.fuse` in the middle.
@mention-bot
Copy link

By analyzing the blame information on this pull request, we identified @lovek323 to be a potential reviewer

@lucabrunox lucabrunox merged commit 7dd9083 into NixOS:master Apr 1, 2016
@lucabrunox
Copy link
Contributor

Built locally, thanks.

@Balletie
Copy link
Contributor Author

Balletie commented Apr 1, 2016

Hey cool, glad I could help :). By the way, for those on older versions of NixOS and who need to use specify mount-points with bindfs in their NixOS configuration, you can use this as a workaround:

fileSystems."/path/to/mount-point" =
  { device = "/path/to/device";
    # FIXME: Hack to workaround "command not found" bug
    fsType = "fuse./run/current-system/sw/bin/bindfs";
    options = "ro,map=501/1000:@20/@10";
  };

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

Successfully merging this pull request may close these issues.

None yet

3 participants