diff --git a/manifests/dpdk.pp b/manifests/dpdk.pp index 543078ae..40cb4ceb 100644 --- a/manifests/dpdk.pp +++ b/manifests/dpdk.pp @@ -99,7 +99,6 @@ class vswitch::dpdk ( $dpdk_configs = { 'other_config:dpdk-extra' => { value => $memory_channels_conf, skip_if_version => '2.5'}, - 'other_config:dpdk-init' => { value => 'true', skip_if_version => '2.5'}, 'other_config:dpdk-socket-mem' => { value => $socket_mem, skip_if_version => '2.5'}, 'other_config:dpdk-lcore-mask' => { value => $dpdk_lcore_mask, skip_if_version => '2.5'}, 'other_config:pmd-cpu-mask' => { value => $pmd_core_mask}, @@ -108,6 +107,14 @@ class vswitch::dpdk ( $dpdk_dependencies = { wait => false, require => Service['openvswitch'], + notify => Vs_config['other_config:dpdk-init'], + } + + vs_config { 'other_config:dpdk-init': + value => 'true', + skip_if_version => '2.5', + require => Service['openvswitch'], + wait => true, } service { 'openvswitch': diff --git a/spec/classes/vswitch_dpdk_spec.rb b/spec/classes/vswitch_dpdk_spec.rb index d08a6d68..71a8ed1f 100644 --- a/spec/classes/vswitch_dpdk_spec.rb +++ b/spec/classes/vswitch_dpdk_spec.rb @@ -52,7 +52,7 @@ describe 'vswitch::dpdk' do is_expected.to contain_file_line('/etc/sysconfig/openvswitch') is_expected.to contain_vs_config('other_config:dpdk-init').with( - :value => 'true', :wait => false, :skip_if_version => "2.5", + :value => 'true', :wait => true, :skip_if_version => "2.5", ) is_expected.to contain_vs_config('other_config:pmd-cpu-mask').with( :value => nil, :wait => false, @@ -83,7 +83,7 @@ describe 'vswitch::dpdk' do :before => 'Service[openvswitch]', ) is_expected.to contain_vs_config('other_config:dpdk-init').with( - :value => 'true', :wait => false, :skip_if_version => "2.5", + :value => 'true', :wait => true, :skip_if_version => "2.5", ) is_expected.to contain_vs_config('other_config:pmd-cpu-mask').with( :value => nil, :wait => false, @@ -116,7 +116,7 @@ describe 'vswitch::dpdk' do :before => 'Service[openvswitch]', ) is_expected.to contain_vs_config('other_config:dpdk-init').with( - :value => 'true', :wait => false, :skip_if_version => "2.5", + :value => 'true', :wait => true, :skip_if_version => "2.5", ) is_expected.to contain_vs_config('other_config:pmd-cpu-mask').with( :value => '3c0000000003c00000', :wait => false, @@ -163,7 +163,7 @@ describe 'vswitch::dpdk' do :before => 'Service[openvswitch]', ) is_expected.to contain_vs_config('other_config:dpdk-init').with( - :value => 'true', :wait => false, :skip_if_version => "2.5", + :value => 'true', :wait => true, :skip_if_version => "2.5", ) is_expected.to contain_vs_config('other_config:pmd-cpu-mask').with( :value => nil, :wait => false,