From 048e9ab1c31c49ed399eaec10053a88ff8b14b51 Mon Sep 17 00:00:00 2001 From: PranaliD Date: Tue, 2 Feb 2021 11:01:12 -0500 Subject: [PATCH] Add parameters for multipath connection in cinder store Adding following 2 parameters for cinder store when multipath usage is enabled in volume connection, - cinder_enforce_multipath - cinder_use_multipath Change-Id: Ic2c86e6a890b58ca7703ea3a3147c8d4ecf13953 (cherry picked from commit 9466c801bc75857334d5b4c8caf0b4175c6fbdc8) (cherry picked from commit 4dca24b62886136a85dafc064dc6cf593d2fa2cf) --- manifests/profile/base/glance/backend/cinder.pp | 12 ++++++++++++ ...ripleo_profile_base_glance_backend_cinder_spec.rb | 4 ++++ 2 files changed, 16 insertions(+) diff --git a/manifests/profile/base/glance/backend/cinder.pp b/manifests/profile/base/glance/backend/cinder.pp index b55592918..b29ee497c 100644 --- a/manifests/profile/base/glance/backend/cinder.pp +++ b/manifests/profile/base/glance/backend/cinder.pp @@ -61,6 +61,14 @@ # (Optional) A valid password for the user specified by `cinder_store_user_name' # Defaults to hiera('glance::backend::cinder::cinder_store_password', undef) # +# [*cinder_enforce_multipath*] +# (Optional) Set to True when multipathd is enabled +# Defaults to hiera('glance::backend::cinder::cinder_enforce_multipath', undef) +# +# [*cinder_use_multipath*] +# (Optional) Set to True when multipathd is enabled +# Defaults to hiera('glance::backend::cinder::cinder_use_multipath', undef) +# # [*store_description*] # (Optional) Provides constructive information about the store backend to # end users. @@ -83,6 +91,8 @@ class tripleo::profile::base::glance::backend::cinder ( $cinder_store_project_name = hiera('glance::backend::cinder::cinder_store_project_name', undef), $cinder_store_user_name = hiera('glance::backend::cinder::cinder_store_user_name', undef), $cinder_store_password = hiera('glance::backend::cinder::cinder_store_password', undef), + $cinder_enforce_multipath = hiera('glance::backend::cinder::cinder_enforce_multipath', undef), + $cinder_use_multipath = hiera('glance::backend::cinder::cinder_use_multipath', undef), $store_description = hiera('tripleo::profile::base::glance::api::glance_store_description', 'Cinder store'), $step = Integer(hiera('step')), ) { @@ -107,6 +117,8 @@ class tripleo::profile::base::glance::backend::cinder ( cinder_store_project_name => $cinder_store_project_name, cinder_store_user_name => $cinder_store_user_name, cinder_store_password => $cinder_store_password, + cinder_enforce_multipath => $cinder_enforce_multipath, + cinder_use_multipath => $cinder_use_multipath, store_description => $store_description_real, } } diff --git a/spec/classes/tripleo_profile_base_glance_backend_cinder_spec.rb b/spec/classes/tripleo_profile_base_glance_backend_cinder_spec.rb index a47ffa43c..f2fdf37fe 100644 --- a/spec/classes/tripleo_profile_base_glance_backend_cinder_spec.rb +++ b/spec/classes/tripleo_profile_base_glance_backend_cinder_spec.rb @@ -47,6 +47,8 @@ describe 'tripleo::profile::base::glance::backend::cinder' do :cinder_store_project_name => 'services', :cinder_store_user_name => 'glance', :cinder_store_password => 'glance_password', + :cinder_enforce_multipath => true, + :cinder_use_multipath => true, :step => 4, } } @@ -61,6 +63,8 @@ describe 'tripleo::profile::base::glance::backend::cinder' do :cinder_store_project_name => 'services', :cinder_store_user_name => 'glance', :cinder_store_password => 'glance_password', + :cinder_enforce_multipath => true, + :cinder_use_multipath => true, :store_description => 'Cinder store', ) end