Add config parameter for cinder mounting needs
This patch is introducing cinder_mount_point_base parameter into glance::backend::multistore::cinder class, so that operators can provide the cinder mount point for NFS volumes. Change-Id: Ib724f6e895716847827be48ed08b01a7a312338f (cherry picked from commit46e9319d8e
) (cherry picked from commit11bd956b9b
) (cherry picked from commit1bd1615234
)
This commit is contained in:
parent
aa0e036fc0
commit
2936eb233e
|
@ -66,6 +66,11 @@
|
||||||
# (optional) A valid password for the user specified by `cinder_store_user_name'
|
# (optional) A valid password for the user specified by `cinder_store_user_name'
|
||||||
# Defaults to $::os_service_default.
|
# Defaults to $::os_service_default.
|
||||||
#
|
#
|
||||||
|
# [*cinder_mount_point_base*]
|
||||||
|
# (Optional) When glance uses cinder as store and cinder backend is NFS, the mount point
|
||||||
|
# would be required to be set with this parameter.
|
||||||
|
# Defaults to $::os_service_default.
|
||||||
|
#
|
||||||
# [*store_description*]
|
# [*store_description*]
|
||||||
# (optional) Provides constructive information about the store backend to
|
# (optional) Provides constructive information about the store backend to
|
||||||
# end users.
|
# end users.
|
||||||
|
@ -81,6 +86,7 @@ define glance::backend::multistore::cinder(
|
||||||
$cinder_store_project_name = $::os_service_default,
|
$cinder_store_project_name = $::os_service_default,
|
||||||
$cinder_store_user_name = $::os_service_default,
|
$cinder_store_user_name = $::os_service_default,
|
||||||
$cinder_store_password = $::os_service_default,
|
$cinder_store_password = $::os_service_default,
|
||||||
|
$cinder_mount_point_base = $::os_service_default,
|
||||||
$store_description = $::os_service_default,
|
$store_description = $::os_service_default,
|
||||||
) {
|
) {
|
||||||
|
|
||||||
|
@ -96,6 +102,7 @@ define glance::backend::multistore::cinder(
|
||||||
"${name}/cinder_store_project_name": value => $cinder_store_project_name;
|
"${name}/cinder_store_project_name": value => $cinder_store_project_name;
|
||||||
"${name}/cinder_store_user_name": value => $cinder_store_user_name;
|
"${name}/cinder_store_user_name": value => $cinder_store_user_name;
|
||||||
"${name}/cinder_store_password": value => $cinder_store_password;
|
"${name}/cinder_store_password": value => $cinder_store_password;
|
||||||
|
"${name}/cinder_mount_point_base": value => $cinder_mount_point_base;
|
||||||
"${name}/store_description": value => $store_description;
|
"${name}/store_description": value => $store_description;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -108,6 +115,7 @@ define glance::backend::multistore::cinder(
|
||||||
"${name}/cinder_store_auth_address": value => $cinder_store_auth_address;
|
"${name}/cinder_store_auth_address": value => $cinder_store_auth_address;
|
||||||
"${name}/cinder_store_project_name": value => $cinder_store_project_name;
|
"${name}/cinder_store_project_name": value => $cinder_store_project_name;
|
||||||
"${name}/cinder_store_user_name": value => $cinder_store_user_name;
|
"${name}/cinder_store_user_name": value => $cinder_store_user_name;
|
||||||
|
"${name}/cinder_mount_point_base": value => $cinder_mount_point_base;
|
||||||
"${name}/cinder_store_password": value => $cinder_store_password;
|
"${name}/cinder_store_password": value => $cinder_store_password;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,6 @@
|
||||||
|
---
|
||||||
|
features:
|
||||||
|
- |
|
||||||
|
A new parameter ``cinder_mount_point_base`` is introduced into
|
||||||
|
``glance::backend::multistore::cinder`` class, so that operators
|
||||||
|
can provide the cinder mount point for NFS volumes.
|
|
@ -40,6 +40,7 @@ describe 'glance::backend::multistore::cinder' do
|
||||||
is_expected.to contain_glance_api_config('cinder/cinder_store_project_name').with_value('<SERVICE DEFAULT>')
|
is_expected.to contain_glance_api_config('cinder/cinder_store_project_name').with_value('<SERVICE DEFAULT>')
|
||||||
is_expected.to contain_glance_api_config('cinder/cinder_store_user_name').with_value('<SERVICE DEFAULT>')
|
is_expected.to contain_glance_api_config('cinder/cinder_store_user_name').with_value('<SERVICE DEFAULT>')
|
||||||
is_expected.to contain_glance_api_config('cinder/cinder_store_password').with_value('<SERVICE DEFAULT>')
|
is_expected.to contain_glance_api_config('cinder/cinder_store_password').with_value('<SERVICE DEFAULT>')
|
||||||
|
is_expected.to contain_glance_api_config('cinder/cinder_mount_point_base').with_value('<SERVICE DEFAULT>')
|
||||||
end
|
end
|
||||||
it 'configures glance-cache.conf' do
|
it 'configures glance-cache.conf' do
|
||||||
is_expected.to_not contain_glance_cache_config('cinder/store_description')
|
is_expected.to_not contain_glance_cache_config('cinder/store_description')
|
||||||
|
@ -52,6 +53,7 @@ describe 'glance::backend::multistore::cinder' do
|
||||||
is_expected.to contain_glance_cache_config('cinder/cinder_store_project_name').with_value('<SERVICE DEFAULT>')
|
is_expected.to contain_glance_cache_config('cinder/cinder_store_project_name').with_value('<SERVICE DEFAULT>')
|
||||||
is_expected.to contain_glance_cache_config('cinder/cinder_store_user_name').with_value('<SERVICE DEFAULT>')
|
is_expected.to contain_glance_cache_config('cinder/cinder_store_user_name').with_value('<SERVICE DEFAULT>')
|
||||||
is_expected.to contain_glance_cache_config('cinder/cinder_store_password').with_value('<SERVICE DEFAULT>')
|
is_expected.to contain_glance_cache_config('cinder/cinder_store_password').with_value('<SERVICE DEFAULT>')
|
||||||
|
is_expected.to contain_glance_cache_config('cinder/cinder_mount_point_base').with_value('<SERVICE DEFAULT>')
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -68,6 +70,7 @@ describe 'glance::backend::multistore::cinder' do
|
||||||
:cinder_store_project_name => 'services',
|
:cinder_store_project_name => 'services',
|
||||||
:cinder_store_user_name => 'glance',
|
:cinder_store_user_name => 'glance',
|
||||||
:cinder_store_password => 'glance',
|
:cinder_store_password => 'glance',
|
||||||
|
:cinder_mount_point_base => '/var/lib/glance/mnt',
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
it 'configures glance-api.conf' do
|
it 'configures glance-api.conf' do
|
||||||
|
@ -81,6 +84,7 @@ describe 'glance::backend::multistore::cinder' do
|
||||||
is_expected.to contain_glance_api_config('cinder/cinder_store_project_name').with_value('services')
|
is_expected.to contain_glance_api_config('cinder/cinder_store_project_name').with_value('services')
|
||||||
is_expected.to contain_glance_api_config('cinder/cinder_store_user_name').with_value('glance')
|
is_expected.to contain_glance_api_config('cinder/cinder_store_user_name').with_value('glance')
|
||||||
is_expected.to contain_glance_api_config('cinder/cinder_store_password').with_value('glance')
|
is_expected.to contain_glance_api_config('cinder/cinder_store_password').with_value('glance')
|
||||||
|
is_expected.to contain_glance_api_config('cinder/cinder_mount_point_base').with_value('/var/lib/glance/mnt')
|
||||||
end
|
end
|
||||||
it 'configures glance-cache.conf' do
|
it 'configures glance-cache.conf' do
|
||||||
is_expected.to_not contain_glance_cache_config('cinder/store_description')
|
is_expected.to_not contain_glance_cache_config('cinder/store_description')
|
||||||
|
@ -93,6 +97,7 @@ describe 'glance::backend::multistore::cinder' do
|
||||||
is_expected.to contain_glance_cache_config('cinder/cinder_store_project_name').with_value('services')
|
is_expected.to contain_glance_cache_config('cinder/cinder_store_project_name').with_value('services')
|
||||||
is_expected.to contain_glance_cache_config('cinder/cinder_store_user_name').with_value('glance')
|
is_expected.to contain_glance_cache_config('cinder/cinder_store_user_name').with_value('glance')
|
||||||
is_expected.to contain_glance_cache_config('cinder/cinder_store_password').with_value('glance')
|
is_expected.to contain_glance_cache_config('cinder/cinder_store_password').with_value('glance')
|
||||||
|
is_expected.to contain_glance_cache_config('cinder/cinder_mount_point_base').with_value('/var/lib/glance/mnt')
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue