Files
nomad/api
Danielle Lancashire afb59bedf5 volumes: Add support for mount propagation
This commit introduces support for configuring mount propagation when
mounting volumes with the `volume_mount` stanza on Linux targets.

Similar to Kubernetes, we expose 3 options for configuring mount
propagation:

- private, which is equivalent to `rprivate` on Linux, which does not allow the
           container to see any new nested mounts after the chroot was created.

- host-to-task, which is equivalent to `rslave` on Linux, which allows new mounts
                that have been created _outside of the container_ to be visible
                inside the container after the chroot is created.

- bidirectional, which is equivalent to `rshared` on Linux, which allows both
                 the container to see new mounts created on the host, but
                 importantly _allows the container to create mounts that are
                 visible in other containers an don the host_

private and host-to-task are safe, but bidirectional mounts can be
dangerous, as if the code inside a container creates a mount, and does
not clean it up before tearing down the container, it can cause bad
things to happen inside the kernel.

To add a layer of safety here, we require that the user has ReadWrite
permissions on the volume before allowing bidirectional mounts, as a
defense in depth / validation case, although creating mounts should also require
a priviliged execution environment inside the container.
2019-10-14 14:09:58 +02:00
..
2017-10-13 14:36:02 -07:00
2017-10-13 13:12:20 -07:00
2017-10-13 13:12:20 -07:00
2018-03-11 19:07:44 +00:00
2019-05-17 16:26:58 -04:00
2017-07-21 16:33:04 -07:00
2018-05-31 10:57:08 -07:00
2019-03-29 15:02:32 -04:00
2019-03-29 15:02:32 -04:00
2017-09-19 10:08:23 -05:00
2017-10-13 14:36:02 -07:00
2019-08-22 08:48:05 +02:00
2018-09-04 16:03:52 -07:00
2017-10-13 14:36:02 -07:00
2017-10-13 14:36:02 -07:00
2017-09-19 10:08:23 -05:00
2017-09-19 10:08:23 -05:00
2017-07-21 16:33:04 -07:00
2016-03-17 16:04:09 -07:00
2017-07-21 16:33:04 -07:00
2019-01-18 15:31:31 -05:00
2019-01-30 12:23:14 -08:00