install ipmitool on ubuntu if driver enabled
If pxe_ipmitool driver is enabled, install ipmitool package on Ubuntu. See https://bugs.launchpad.net/cloud-archive/+bug/1572800 to be fixed in packaging one day. In the meantime, automatically install it, and fix orchestration to make sure the package is installed before ironic-conductor get started otherwise service will fail to load the driver. Change-Id: I34014d3c44876091f698023c6b896f3d55b7756d
This commit is contained in:
parent
d0e53354b9
commit
76cb4f73e0
@ -63,7 +63,7 @@ class ironic::conductor (
|
||||
|
||||
# Install package
|
||||
if $::ironic::params::conductor_package {
|
||||
Package['ironic-conductor'] -> Service['ironic-conductor']
|
||||
Package<| tag == 'ironic-package' |> -> Service['ironic-conductor']
|
||||
package { 'ironic-conductor':
|
||||
ensure => $package_ensure,
|
||||
name => $::ironic::params::conductor_package,
|
||||
|
@ -247,6 +247,17 @@ class ironic (
|
||||
|
||||
validate_array($enabled_drivers)
|
||||
|
||||
# On Ubuntu, ipmitool dependency is missing and ironic-conductor fails to start.
|
||||
# https://bugs.launchpad.net/cloud-archive/+bug/1572800
|
||||
if member($enabled_drivers, 'pxe_ipmitool') and $::osfamily == 'Debian' {
|
||||
ensure_packages('ipmitool',
|
||||
{
|
||||
ensure => $package_ensure,
|
||||
tag => ['openstack', 'ironic-package'],
|
||||
}
|
||||
)
|
||||
}
|
||||
|
||||
if is_array($glance_api_servers) {
|
||||
ironic_config {
|
||||
'glance/glance_api_servers': value => join($glance_api_servers, ',');
|
||||
|
@ -251,6 +251,15 @@ describe 'ironic' do
|
||||
end
|
||||
|
||||
it_configures 'ironic'
|
||||
|
||||
# https://bugs.launchpad.net/cloud-archive/+bug/1572800
|
||||
it 'installs ipmitool package' do
|
||||
is_expected.to contain_package('ipmitool').with(
|
||||
:ensure => 'present',
|
||||
:name => 'ipmitool',
|
||||
:tag => ['openstack', 'ironic-package'],
|
||||
)
|
||||
end
|
||||
end
|
||||
|
||||
context 'on RedHat platforms' do
|
||||
|
Loading…
Reference in New Issue
Block a user