diff options
-rw-r--r-- | openstack-nova.configure | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/openstack-nova.configure b/openstack-nova.configure index ee937007..0a4d7505 100644 --- a/openstack-nova.configure +++ b/openstack-nova.configure @@ -66,4 +66,6 @@ sed -i "s/192\.168\.122\./192\.168\.1\./g" \ # Add nova to sudoers controlling which commands is running as a root # using the openstack rootwrap. ########################################################################## -echo 'nova ALL=(ALL) NOPASSWD: /usr/bin/nova-rootwrap /etc/nova/rootwrap.conf *' >> "$ROOT/etc/sudoers" +install -D -m 0440 /proc/self/fd/0 <<'EOF' "$ROOT"/etc/sudoers.d/nova-rootwrap +nova ALL=(root) NOPASSWD: /usr/bin/nova-rootwrap /etc/nova/rootwrap.conf * +EOF |