summaryrefslogtreecommitdiff
path: root/strata/openstack-services/nova.morph
diff options
context:
space:
mode:
authorFrancisco Redondo Marchena <francisco.marchena@codethink.co.uk>2015-02-16 17:34:52 +0000
committerFrancisco Redondo Marchena <francisco.marchena@codethink.co.uk>2015-03-02 17:45:43 +0000
commit94f31f6c4bd9fed0235fc6d19ab571d3415ca8a3 (patch)
tree1c04f6d65c16852c47db39eb9f084c8ed58325ba /strata/openstack-services/nova.morph
parent3ebd0a08991627d2e5e51be7b4dc93488b5e04f5 (diff)
downloaddefinitions-94f31f6c4bd9fed0235fc6d19ab571d3415ca8a3.tar.gz
Add sudoers files for cinder, nova and neutron on post-install time
Diffstat (limited to 'strata/openstack-services/nova.morph')
-rw-r--r--strata/openstack-services/nova.morph7
1 files changed, 7 insertions, 0 deletions
diff --git a/strata/openstack-services/nova.morph b/strata/openstack-services/nova.morph
index 4bf15bc7..98ac9854 100644
--- a/strata/openstack-services/nova.morph
+++ b/strata/openstack-services/nova.morph
@@ -7,3 +7,10 @@ post-install-commands:
# Move rootwrap files to a proper location
- mkdir -p "$DESTDIR"/etc/nova/rootwrap.d
- install -D -m 644 etc/nova/rootwrap.d/* "$DESTDIR"/etc/nova/rootwrap.d/
+# Add nova 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/nova-rootwrap
+ nova ALL=(root) NOPASSWD: /usr/bin/nova-rootwrap /etc/nova/rootwrap.conf *
+ EOF