Files
docker-cli/components/engine/daemon
Kir Kolyshkin d00ceca6f0 btrfs: ensure graphdriver home is bind mount
For some reason, shared mount propagation between the host
and a container does not work for btrfs, unless container
root directory (i.e. graphdriver home) is a bind mount.

The above issue was reproduced on SLES 12sp3 + btrfs using
the following script:

	#!/bin/bash
	set -eux -o pipefail

	# DIR should not be under a subvolume
	DIR=${DIR:-/lib}
	MNT=$DIR/my-mnt
	FILE=$MNT/file

	ID=$(docker run -d --privileged -v $DIR:$DIR:rshared ubuntu sleep 24h)
	docker exec $ID mkdir -p $MNT
	docker exec $ID mount -t tmpfs tmpfs $MNT
	docker exec $ID touch $FILE
	ls -l $FILE
	umount $MNT
	docker rm -f $ID

which fails this way:

	+ ls -l /lib/my-mnt/file
	ls: cannot access '/lib/my-mnt/file': No such file or directory

meaning the mount performed inside a priviledged container is not
propagated back to the host (even if all the mounts have "shared"
propagation mode).

The remedy to the above is to make graphdriver home a bind mount.

Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
(cherry picked from commit 16d822bba8ac5ab22c8697750f700403bca3dbf3)
Upstream-commit: fa8ac946165b8004a15e85744e774ed6ba99fd38
Component: engine
2018-10-12 09:29:38 -07:00
..
2018-06-13 09:04:30 +02:00
2018-02-05 16:51:57 -05:00
2018-02-05 16:51:57 -05:00
2018-09-06 18:39:22 -07:00
2018-02-05 16:51:57 -05:00
2017-09-06 12:05:19 -04:00
2018-02-05 16:51:57 -05:00
2018-04-23 13:52:44 -07:00
2018-02-05 16:51:57 -05:00
2018-02-09 11:24:09 -08:00
2018-02-05 16:51:57 -05:00
2018-02-05 16:51:57 -05:00
2018-07-26 11:17:56 -07:00
2018-06-13 09:04:30 +02:00
2018-07-26 11:17:56 -07:00
2018-07-26 11:17:56 -07:00
2018-02-05 16:51:57 -05:00
2018-06-13 09:04:30 +02:00
2018-02-05 16:51:57 -05:00
2018-02-05 16:51:57 -05:00
2018-02-21 18:26:16 -05:00
2018-06-13 09:04:30 +02:00
2018-02-05 16:51:57 -05:00
2018-02-05 16:51:57 -05:00
2018-04-23 13:52:44 -07:00
2018-06-13 09:04:30 +02:00
2018-10-04 21:20:54 +02:00
2018-02-05 16:51:57 -05:00
2018-06-13 09:04:30 +02:00
2018-02-05 16:51:57 -05:00
2018-02-05 16:51:57 -05:00
2018-02-05 16:51:57 -05:00
2018-02-05 16:51:57 -05:00
2018-08-17 09:36:56 -07:00
2018-02-05 16:51:57 -05:00
2018-02-05 16:51:57 -05:00
2018-02-05 16:51:57 -05:00
2018-06-13 09:04:30 +02:00
2018-02-05 16:51:57 -05:00
2018-02-05 16:51:57 -05:00
2018-02-05 16:51:57 -05:00
2018-06-13 09:04:30 +02:00
2018-02-05 16:51:57 -05:00
2018-02-05 16:51:57 -05:00
2018-02-05 16:51:57 -05:00
2018-02-05 16:51:57 -05:00
2018-02-05 16:51:57 -05:00
2018-02-05 16:51:57 -05:00
2018-02-26 16:49:37 -05:00
2018-02-05 16:51:57 -05:00
2018-02-05 16:51:57 -05:00
2018-04-23 13:52:44 -07:00
2018-02-05 16:51:57 -05:00
2018-02-05 16:51:57 -05:00
2018-06-13 09:04:30 +02:00
2018-05-23 17:50:54 +02:00
2018-02-05 16:51:57 -05:00
2018-02-05 16:51:57 -05:00
2018-04-23 13:52:44 -07:00