diff options
| author | Steven Dake <stdake@cisco.com> | 2015-09-29 01:37:35 -0700 |
|---|---|---|
| committer | Steven Dake <stdake@cisco.com> | 2015-09-29 01:37:35 -0700 |
| commit | 655d88e3a1054b61d9ede8b99c5ee95f11948227 (patch) | |
| tree | 6e73bd65f30890401f2bd6f8b0febce9c555c2cd | |
| parent | 4f15ac800855ca2b5625ac6e3efbb90f7dc62c16 (diff) | |
| download | kolla-655d88e3a1054b61d9ede8b99c5ee95f11948227.tar.gz kolla-655d88e3a1054b61d9ede8b99c5ee95f11948227.zip | |
Make libvirt function on CentOS
Recent regressions in the code base removed permission setting of
/dev/kvm to root:kvm 660 permissions which are default for CentOS's
version of libvirt.
Also Libvirt must be able to read its cnofiguration file, which was
previously 600 root:root. Now its 644 root:root so its always readable.
This is fine, since this file doesn't contain any secret information.
Change-Id: Id87cf5da8e37bc5bb613ce919d0293803d0fe5ed
Closes-Bug: #1500733
| -rw-r--r-- | ansible/roles/nova/templates/nova-libvirt.json.j2 | 2 | ||||
| -rwxr-xr-x | docker/nova/nova-libvirt/start.sh | 8 |
2 files changed, 9 insertions, 1 deletions
diff --git a/ansible/roles/nova/templates/nova-libvirt.json.j2 b/ansible/roles/nova/templates/nova-libvirt.json.j2 index 598cc9f64..78d38683a 100644 --- a/ansible/roles/nova/templates/nova-libvirt.json.j2 +++ b/ansible/roles/nova/templates/nova-libvirt.json.j2 @@ -5,7 +5,7 @@ "source": "/opt/kolla/config_files/libvirtd.conf", "dest": "/etc/libvirt/libvirtd.conf", "owner": "root", - "perm": "0600" + "perm": "0644" }{% if enable_ceph | bool %}, { "source": "/opt/kolla/config_files/secrets", diff --git a/docker/nova/nova-libvirt/start.sh b/docker/nova/nova-libvirt/start.sh index a083e7bac..df3b0e5a9 100755 --- a/docker/nova/nova-libvirt/start.sh +++ b/docker/nova/nova-libvirt/start.sh @@ -4,4 +4,12 @@ set -o errexit # Loading common functions. source /opt/kolla/kolla-common.sh +# TODO(SamYaple): Tweak libvirt.conf rather than change permissions. +# Fix permissions for libvirt +# Do not remove unless CentOS has been validated +if [[ -c /dev/kvm ]]; then + chmod 660 /dev/kvm + chown root:kvm /dev/kvm +fi + exec $CMD |
