KVM support for CentOS 5 (5.8, maybe 5.9 if such thing comes out).

This commit is contained in:
Ossi Herrala 2012-04-02 12:55:41 +00:00
parent 2e15368940
commit e8263790fb

View file

@ -29,11 +29,26 @@ class libvirt::client {
# #
class libvirt::kvm inherits libvirt::client { class libvirt::kvm inherits libvirt::client {
case operatingsystem {
centos,fedora: {
case $operatingsystemrelease {
'/5\.[8-9]': {
package { "kvm":
ensure => installed,
before => Service["libvirtd"],
require => [ User["qemu"], Group["qemu"] ],
}
}
'/6\.[0-9]': {
package { "qemu-kvm": package { "qemu-kvm":
ensure => installed, ensure => installed,
before => Service["libvirtd"], before => Service["libvirtd"],
require => [ User["qemu"], Group["qemu"] ], require => [ User["qemu"], Group["qemu"] ],
} }
}
}
}
}
if !$libvirt_admingroup { if !$libvirt_admingroup {
$libvirt_admingroup = "root" $libvirt_admingroup = "root"
@ -41,7 +56,7 @@ class libvirt::kvm inherits libvirt::client {
file { "/etc/libvirt/libvirtd.conf": file { "/etc/libvirt/libvirtd.conf":
ensure => present, ensure => present,
mode => "0644", mode => 0644,
owner => "root", owner => "root",
group => "root", group => "root",
content => template("libvirt/libvirtd.conf.erb"), content => template("libvirt/libvirtd.conf.erb"),