From 8ef4e992f101668e86a3ab5d29bdbe4f7da3cd1d Mon Sep 17 00:00:00 2001 From: Francisco Redondo Marchena Date: Mon, 16 Feb 2015 17:34:52 +0000 Subject: Add sudoers files for cinder, nova and neutron on post-install time --- strata/openstack-services/cinder.morph | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'strata/openstack-services/cinder.morph') diff --git a/strata/openstack-services/cinder.morph b/strata/openstack-services/cinder.morph index bfc31026..eafc7cea 100644 --- a/strata/openstack-services/cinder.morph +++ b/strata/openstack-services/cinder.morph @@ -7,3 +7,10 @@ post-install-commands: # Move rootwrap files to a proper location - mkdir -p "$DESTDIR"/etc/cinder/rootwrap.d - install -D -m 644 etc/cinder/rootwrap.d/* "$DESTDIR"/etc/cinder/rootwrap.d/ +# Add cinder to sudoers controlling which commands will run as a root +# using the openstack rootwrap. +- mkdir -p "$DESTDIR"/etc/sudoers.d +- | + install -D -m 0440 /proc/self/fd/0 <<'EOF' "$DESTDIR"/etc/sudoers.d/cinder-rootwrap + cinder ALL=(root) NOPASSWD: /usr/bin/cinder-rootwrap /etc/cinder/rootwrap.conf * + EOF -- cgit v1.2.1