-
Notifications
You must be signed in to change notification settings - Fork 2k
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
Supporting bind mounts in exec driver? #2115
Comments
I hope this can be addressed as part of the generic support for volumes instead. I would like to be able to also mount cephfs volumes in addition to host's volumes. |
We actually facing the same situations: we need to mount some locations from host OS inside chrooted environment (rather than copy them) such as network mounts, external storage (PanFs) and just some dir that should we shared across allocations. Without this feature we just cannot run part of our applications. :( |
@ndriessen @c4milo I submitted a PR with this feature implemented - #2333. If you would like to give it a try I can upload a build for you. |
Is there any information where this is on the roadmap? |
What are the plans for supporting bind mounts in the exec (and java) driver? It appears that much of the preparations for this functionality are already in place. @dadgar can you shed some light on this? |
Hey folks, |
I'm going to lock this issue because it has been closed for 120 days ⏳. This helps our maintainers find and focus on the active issues. |
Hi,
I am deploying a webserver as a service job using the exec driver with nomad. The idea is that all artifacts for other jobs are served by this web server.
However, at this moment it is impossible to use a folder / mount on the host that is mapped into the chroot and is being synchronized in 2 ways
e.g: if uploading a file to the webserver, it will write in the the chrooted folder from the host and changes are not reflected back to the original location on the host.
A simple solution would be to bind mount the folder after the new root has been created, but the exec driver doesn't allow to customize how the isolation happens in any way.
It would be great if the client configuration options could for example support something along these lines:
client { options { exec_bind_mounts { "/var/www" = "/var/www/" } } }
This would result in the driver doing a
mount --bind /var/www /var/lib/nomad/alloc/2919d1c7-d10e-0ff4-e7ab-6767133045c9/fileserve/var/www
before starting the actual command specified by the job.The host system could then use any available tech to sync the host folder across nodes. This would allow an easy way for persistent storage for the exec driver I believe without introduces complexity in the driver.
The text was updated successfully, but these errors were encountered: