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
This commit is contained in:
Steven Dake 2015-09-29 01:37:35 -07:00
parent 4f15ac8008
commit 655d88e3a1
2 changed files with 9 additions and 1 deletions

View File

@ -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",

View File

@ -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