From 84ff895a06c3e1de84a522db89207688c8a62899 Mon Sep 17 00:00:00 2001 From: Dieter Reuter Date: Wed, 20 Jul 2016 01:08:19 +0200 Subject: [PATCH] Add a Raspbian specific systemd unit file, use overlay by default Signed-off-by: Dieter Reuter --- hack/install.sh | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/hack/install.sh b/hack/install.sh index 469e87ab04fbb..e2a86f5ba34d4 100644 --- a/hack/install.sh +++ b/hack/install.sh @@ -389,12 +389,10 @@ do_install() { } if [ "$lsb_dist" = "raspbian" ]; then - # overlay is preferred to use on Raspbian - if [ ! -f /etc/modules-load.d/docker.conf ]; then - # Load kernel module 'overlay' at boot time - ( set -x; $sh_c "modprobe overlay" ) - ( set -x; $sh_c "echo overlay > /etc/modules-load.d/docker.conf" ) - fi + # Create Raspbian specific systemd init file, use overlay by default + ( set -x; $sh_c "mkdir -p /etc/systemd/system" ) + ( set -x; $sh_c "$curl https://raw.githubusercontent.com/docker/docker/master/contrib/init/systemd/docker.service > /etc/systemd/system/docker.service" ) + ( set -x; $sh_c "sed -i 's/dockerd/dockerd --storage-driver overlay/' /etc/systemd/system/docker.service" ) else # aufs is preferred over devicemapper; try to ensure the driver is available. if ! grep -q aufs /proc/filesystems && ! $sh_c 'modprobe aufs'; then