Allow the vcpu_pin_set to be configurable
This patch allows puppet-nova to handle empty lists for vcpu_pin_set. Implements: blueprint tripleo-ovs-dpdk Change-Id: Ib734ed877edea6879b8e3bde15512be9e90d180d Signed-off-by: karthik s <ksundara@redhat.com>
This commit is contained in:
@@ -219,13 +219,18 @@ class nova::compute (
|
||||
'DEFAULT/compute_manager': value => $compute_manager;
|
||||
'DEFAULT/heal_instance_info_cache_interval': value => $heal_instance_info_cache_interval;
|
||||
'DEFAULT/allow_resize_to_same_host': value => $allow_resize_to_same_host;
|
||||
'DEFAULT/vcpu_pin_set': value => join(any2array($vcpu_pin_set), ',');
|
||||
'key_manager/api_class': value => $keymgr_api_class;
|
||||
'barbican/auth_endpoint': value => $barbican_auth_endpoint;
|
||||
'barbican/barbican_endpoint': value => $barbican_endpoint;
|
||||
'barbican/barbican_api_version': value => $barbican_api_version;
|
||||
}
|
||||
|
||||
$vcpu_pin_set_real = pick(join(any2array($vcpu_pin_set), ','), $::os_service_default)
|
||||
|
||||
nova_config {
|
||||
'DEFAULT/vcpu_pin_set': value => $vcpu_pin_set_real;
|
||||
}
|
||||
|
||||
if ($vnc_enabled) {
|
||||
include ::nova::vncproxy::common
|
||||
|
||||
|
@@ -142,6 +142,17 @@ describe 'nova::compute' do
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
context 'when vcpu_pin_set is empty' do
|
||||
let :params do
|
||||
{ :vcpu_pin_set => "" }
|
||||
end
|
||||
|
||||
it 'clears vcpu_pin_set configuration' do
|
||||
is_expected.to contain_nova_config('DEFAULT/vcpu_pin_set').with(:value => '<SERVICE DEFAULT>')
|
||||
end
|
||||
end
|
||||
|
||||
context 'with neutron_enabled set to false' do
|
||||
let :params do
|
||||
{ :neutron_enabled => false }
|
||||
|
Reference in New Issue
Block a user