b6294ce7a2
CentOS Stream is Rolling-release distro that tracks just ahead of Red Hat Enterprise Linux (RHEL) development [1]. While not recommended in RDO, it's used to find potential issues before they are found in official CentOS 8. CentOS Stream is reported by facter as '8' with no minor version, breaking the logic to discover the libvirtd version. This patch is setting the version of libvirtd to 5.6 for all CdentOS 8 releases, including Stream, as 8.0 is no longer supported. [1] https://www.centos.org/centos-stream/ Change-Id: I468ecf06ac6e0853fbb296c011f20d63e38f6922
46 lines
1.3 KiB
Puppet
46 lines
1.3 KiB
Puppet
# Class: nova::compute::libvirt::version
|
|
#
|
|
# Try to detect the version by OS
|
|
# Right now this is only used by nova::compute::libvirt::qemu and the
|
|
# interesting version is with which release there will be libvirt 4.5
|
|
# or higher.
|
|
#
|
|
class nova::compute::libvirt::version {
|
|
# This will be 7.5 or 7.6 on RedHat, 9 on Debian, 18.10 or cosmic on Ubuntu, etc.
|
|
case $facts['os']['family'] {
|
|
'RedHat': {
|
|
case $facts['os']['name'] {
|
|
'RedHat', 'CentOS': {
|
|
if versioncmp($facts['os']['release']['full'], '8') >= 0 {
|
|
$default = '5.6'
|
|
} elsif versioncmp($facts['os']['release']['full'], '7.6') >= 0 {
|
|
$default = '4.5'
|
|
} else {
|
|
$default = '3.9'
|
|
}
|
|
}
|
|
'Fedora': {
|
|
if versioncmp($facts['os']['release']['full'], '29') >= 0 {
|
|
$default = '4.5'
|
|
} else {
|
|
$default = '3.9'
|
|
}
|
|
}
|
|
default: {
|
|
$default = '3.9'
|
|
}
|
|
}
|
|
}
|
|
'Debian': {
|
|
if versioncmp($facts['os']['release']['full'], '18.04') >= 0 {
|
|
$default = '6.0'
|
|
} else {
|
|
$default = '4.0'
|
|
}
|
|
}
|
|
default: {
|
|
fail("Class['nova::compute::libvirt::version']: Unsupported osfamily: ${::osfamily}")
|
|
}
|
|
}
|
|
}
|