Debian/Ubuntu: Fix missing nova-compute-ironic
This package should be installed to use ironic virt driver. Closes-Bug: #2042383 Change-Id: I3b7ac19b347f3a5deb68d724de32246bb8dc1075
This commit is contained in:
parent
29378852ad
commit
1a768d4d01
@ -4,18 +4,30 @@
|
||||
#
|
||||
# === Parameters:
|
||||
#
|
||||
# [*ensure_package*]
|
||||
# (optional) The state of nova packages
|
||||
# Defaults to 'present'
|
||||
#
|
||||
# [*compute_driver*]
|
||||
# (optional) Compute driver.
|
||||
# Defaults to 'ironic.IronicDriver'
|
||||
#
|
||||
class nova::compute::ironic (
|
||||
$compute_driver = 'ironic.IronicDriver',
|
||||
$ensure_package = 'present',
|
||||
$compute_driver = 'ironic.IronicDriver',
|
||||
) {
|
||||
|
||||
include nova::deps
|
||||
require nova::ironic::common
|
||||
include ironic::client
|
||||
|
||||
if($facts['os']['family'] == 'Debian') {
|
||||
package { 'nova-compute-ironic':
|
||||
ensure => $ensure_package,
|
||||
tag => ['openstack', 'nova-package'],
|
||||
}
|
||||
}
|
||||
|
||||
nova_config {
|
||||
'DEFAULT/compute_driver': value => $compute_driver;
|
||||
}
|
||||
|
5
releasenotes/notes/bug-2042383-76b5bd1579f9310d.yaml
Normal file
5
releasenotes/notes/bug-2042383-76b5bd1579f9310d.yaml
Normal file
@ -0,0 +1,5 @@
|
||||
---
|
||||
fixes:
|
||||
- |
|
||||
Now the ``nova::compute::ironic`` class installs
|
||||
the ``nova-compute-ironic`` package in Debian or Ubuntu.
|
@ -2,8 +2,7 @@ require 'spec_helper'
|
||||
|
||||
describe 'nova::compute::ironic' do
|
||||
|
||||
shared_examples_for 'nova-compute-ironic' do
|
||||
|
||||
shared_examples_for 'nova::compute::ironic' do
|
||||
context 'with default parameters' do
|
||||
it 'configures ironic in nova.conf' do
|
||||
is_expected.to contain_nova_config('DEFAULT/compute_driver').with_value('ironic.IronicDriver')
|
||||
@ -30,6 +29,17 @@ describe 'nova::compute::ironic' do
|
||||
end
|
||||
end
|
||||
|
||||
shared_examples_for 'nova::compute::ironic in Debian' do
|
||||
context 'with default parameters' do
|
||||
it 'installs nova-compute-ironic' do
|
||||
is_expected.to contain_package('nova-compute-ironic').with(
|
||||
:ensure => 'present',
|
||||
:tag => ['openstack', 'nova-package'],
|
||||
)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
on_supported_os({
|
||||
:supported_os => OSDefaults.get_supported_os
|
||||
}).each do |os,facts|
|
||||
@ -38,15 +48,10 @@ describe 'nova::compute::ironic' do
|
||||
facts.merge!(OSDefaults.get_facts())
|
||||
end
|
||||
|
||||
let(:platform_params) do
|
||||
case facts[:os]['family']
|
||||
when 'Debian'
|
||||
{}
|
||||
when 'RedHat'
|
||||
{}
|
||||
end
|
||||
it_configures 'nova::compute::ironic'
|
||||
if facts[:os]['family'] == 'Debian'
|
||||
it_configures 'nova::compute::ironic in Debian'
|
||||
end
|
||||
it_configures 'nova-compute-ironic'
|
||||
end
|
||||
end
|
||||
end
|
||||
|
Loading…
Reference in New Issue
Block a user