Parallels / docker-machine-parallels

Parallels driver for Docker Machine https://github.com/docker/machine
MIT License
471 stars 35 forks source link

Feature request: support NFS as alternative means to mount /Users #29

Closed posita closed 8 years ago

posita commented 8 years ago

There are host of permissions-related issues with both Docker in general as well as using it with OS X host volumes in particular (e.g., via Boot2Docker). Here is a decent summary:

Most of these issue can be worked around by careful use of NFS with the mapall option (see, e.g., this https://github.com/boot2docker/boot2docker/issues/587#issuecomment-66935011, and even this https://github.com/Parallels/docker-machine-parallels/issues/12#issuecomment-155386484).

Parallels already supports a --parallels-no-share option (perhaps meant to address this Boot2Docker shortcoming). It might be nice to enable something like this:

% docker-machine create --help --driver parallels
...
  --parallels-share-type "native"   "native" or "nfs[:<mount_options>]" where
                                    <mount_options> are optional NFS options,
                                    such as "mapall=999:999,nolock,sync"
...

Then you could do something like:

% docker-machine create --driver parallels ... --parallels-share-type "nfs:mapall=$( id -u ):$( id -g )" ...
legal90 commented 8 years ago

@posita, Thank you, this is a good idea. However I don't think that it should be implemented on the Parallels driver's side. NFS support should be implemented in both of Boot2Docker and Docker Machine itself, but not in a driver because it is not related to the virtualization system directly.

The good example is Vagrant and how NFS support is implemented there. Following this way, Docker Machine should manage NFS exports on the host side and also it should mount NFS folders on the guest side (during the provision step). So, this feature is mostly host-specific (Windows doesn't support it) rather that provider-specific (it should work for VirtualBox and VMware by the same way).

I think it's better to continue tracking https://github.com/docker/machine/issues/13 and push the idea of NFS share support in Docker Machine project.

ducdebreme commented 8 years ago

subscribing