Add parameter for compute/live_migration_wait_for_vif_plug

Add parameter `live_migration_wait_for_vif_plug` to
whether to wait for ``network-vif-plugged`` events before
starting guest transfer.

Also fixes some allignment in compute.pp

Change-Id: I0048d1f57eeb3418b52f225f87810ea1a7250a0f
This commit is contained in:
Martin Schuppert
2019-06-03 11:20:29 +02:00
parent ffe4b7b05e
commit 282ef4e391
3 changed files with 36 additions and 20 deletions

View File

@@ -177,6 +177,10 @@
# tunneled networks.
# Defaults to []
#
# [*live_migration_wait_for_vif_plug*]
# (optional) whether to wait for ``network-vif-plugged`` events before starting guest transfer
# Defaults to $::os_service_default
#
# DEPRECATED PARAMETERS
#
# [*vnc_keymap*]
@@ -221,6 +225,7 @@ class nova::compute (
$reserved_huge_pages = $::os_service_default,
$neutron_physnets_numa_nodes_mapping = {},
$neutron_tunnel_numa_nodes = [],
$live_migration_wait_for_vif_plug = $::os_service_default,
# DEPRECATED PARAMETERS
$vnc_keymap = undef,
) {
@@ -308,6 +313,7 @@ class nova::compute (
'DEFAULT/sync_power_state_interval': value => $sync_power_state_interval;
'compute/consecutive_build_service_disable_threshold':
value => $consecutive_build_service_disable_threshold;
'compute/live_migration_wait_for_vif_plug': value => $live_migration_wait_for_vif_plug;
}
ensure_resource('nova_config', 'DEFAULT/allow_resize_to_same_host', { value => $allow_resize_to_same_host })

View File

@@ -0,0 +1,6 @@
---
features:
- |
Add parameter `live_migration_wait_for_vif_plug` to
whether to wait for ``network-vif-plugged`` events before
starting guest transfer.

View File

@@ -40,6 +40,7 @@ describe 'nova::compute' do
it { is_expected.to contain_nova_config('DEFAULT/sync_power_state_interval').with_value('<SERVICE DEFAULT>') }
it { is_expected.to contain_nova_config('compute/consecutive_build_service_disable_threshold').with_value('<SERVICE DEFAULT>') }
it { is_expected.to contain_nova_config('DEFAULT/reserved_huge_pages').with_value('<SERVICE DEFAULT>') }
it { is_expected.to contain_nova_config('compute/live_migration_wait_for_vif_plug').with_value('<SERVICE DEFAULT>') }
it { is_expected.to_not contain_package('cryptsetup').with( :ensure => 'present' )}
@@ -106,6 +107,7 @@ describe 'nova::compute' do
:sync_power_state_interval => '0',
:verify_glance_signatures => true,
:consecutive_build_service_disable_threshold => '9',
:live_migration_wait_for_vif_plug => true,
}
end
@@ -169,6 +171,8 @@ describe 'nova::compute' do
it { is_expected.to contain_nova_config('DEFAULT/resume_guests_state_on_host_boot').with_value(true) }
it { is_expected.to contain_nova_config('glance/verify_glance_signatures').with_value(true) }
it { is_expected.to contain_nova_config('compute/live_migration_wait_for_vif_plug').with_value(true) }
it 'configures nova config_drive_format to vfat' do
is_expected.to contain_nova_config('DEFAULT/config_drive_format').with_value('vfat')
is_expected.to_not contain_package('genisoimage').with(