From 59c410e6dd74b2bf4aaa36f36f172fd10481ea7c Mon Sep 17 00:00:00 2001 From: Oliver Walsh Date: Tue, 7 Nov 2017 00:24:59 +0000 Subject: Unset MountFlags in docker.service systemd directives Required to allow bind propegation options to be set on individual bind-mounts. See https://github.com/moby/moby/issues/19625. Also https://access.redhat.com/articles/2938171 for rational for using this option in RHEL/CentOS 7.3. Change-Id: I8a63c044e15d7ca0f54654e9fc9c5d878461aa25 Related-bug: 1730533 (cherry picked from commit 2366b5b2fe3bc97d11aa9c3a65660ff78a6dc6f7) --- manifests/profile/base/docker.pp | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'manifests') diff --git a/manifests/profile/base/docker.pp b/manifests/profile/base/docker.pp index 73731ad..d3f6fe7 100644 --- a/manifests/profile/base/docker.pp +++ b/manifests/profile/base/docker.pp @@ -83,6 +83,22 @@ class tripleo::profile::base::docker ( ensure => installed, } + $docker_unit_override="[Service]\nMountFlags=\n" + + file {'/etc/systemd/system/docker.service.d': + ensure => directory, + require => Package['docker'], + } + -> file {'/etc/systemd/system/docker.service.d/99-unset-mountflags.conf': + content => $docker_unit_override, + } + ~> exec { 'systemd daemon-reload': + command => 'systemctl daemon-reload', + path => ['/usr/bin', '/usr/sbin'], + refreshonly => true, + notify => Service['docker'] + } + service { 'docker': ensure => 'running', enable => true, -- cgit 1.2.3-korg