From 4a224054c3470b1ab76f0ad8fc37a759876fd952 Mon Sep 17 00:00:00 2001 From: Francesco Santoro Date: Wed, 12 Oct 2016 15:30:46 +0200 Subject: [PATCH] 6wind-virtual-accelerator-plugin: fix to license file installation Always install virtual accelerator license file (if available) Change-Id: I9189fd1582318d8bfeb3831f545b4c9b1f9d9dec Closes-bug: 1632712 Signed-off-by: Francesco Santoro --- .../virtual_accelerator/manifests/config.pp | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) diff --git a/deployment_scripts/puppet/modules/virtual_accelerator/manifests/config.pp b/deployment_scripts/puppet/modules/virtual_accelerator/manifests/config.pp index a8c1678..9dd581e 100644 --- a/deployment_scripts/puppet/modules/virtual_accelerator/manifests/config.pp +++ b/deployment_scripts/puppet/modules/virtual_accelerator/manifests/config.pp @@ -17,6 +17,7 @@ class virtual_accelerator::config inherits virtual_accelerator { $fp_conf_file = "/usr/local/etc/fast-path.env" $hugepages_dir = "/dev/hugepages" + $license_file = $virtual_accelerator::va_license_file exec { 'copy_template': command => "cp /usr/local/etc/fast-path.env.tmpl ${fp_conf_file}", @@ -26,6 +27,13 @@ class virtual_accelerator::config inherits virtual_accelerator { path => '/usr/local/bin/', } + if $license_file != '' and $license_file != undef { + file {"/usr/local/etc/6wind_va.lic": + ensure => file, + content => $license_file, + } + } + if $advanced_params == true { $custom_conf_file = $virtual_accelerator::va_conf_file @@ -52,15 +60,6 @@ class virtual_accelerator::config inherits virtual_accelerator { path => '/usr/local/bin/', } } - - $license_file = $virtual_accelerator::va_license_file - - if $license_file != '' and $license_file != undef { - file {"/usr/local/etc/6wind_va.lic": - ensure => file, - content => $license_file, - } - } - } + }