Add ability to configure Cinder's NFS snapshot support
Add the ability to configure the nfs_snapshot_support parameter associated with Cinder's NFS backend. Change-Id: I4df8e3941eb074339e399e5a5c44fa411ff21560
This commit is contained in:
parent
91261fd302
commit
cadde08bc7
@ -33,6 +33,10 @@
|
||||
# (Optional) List of mount options for the NFS share
|
||||
# Defaults to ''
|
||||
#
|
||||
# [*cinder_nfs_snapshot_support*]
|
||||
# (Optional) Whether to enable support for snapshots in the NFS driver.
|
||||
# Defaults to $::os_service_default
|
||||
#
|
||||
# [*cinder_nas_secure_file_operations*]
|
||||
# (Optional) Allow network-attached storage systems to operate in a secure
|
||||
# environment where root level access is not permitted. If set to False,
|
||||
@ -60,6 +64,7 @@ class tripleo::profile::base::cinder::volume::nfs (
|
||||
$backend_name = hiera('cinder::backend::nfs::volume_backend_name', 'tripleo_nfs'),
|
||||
$backend_availability_zone = hiera('cinder::backend::nfs::backend_availability_zone', undef),
|
||||
$cinder_nfs_mount_options = '',
|
||||
$cinder_nfs_snapshot_support = $::os_service_default,
|
||||
$cinder_nas_secure_file_operations = $::os_service_default,
|
||||
$cinder_nas_secure_file_permissions = $::os_service_default,
|
||||
$step = Integer(hiera('step')),
|
||||
@ -73,6 +78,7 @@ class tripleo::profile::base::cinder::volume::nfs (
|
||||
nfs_servers => $cinder_nfs_servers,
|
||||
nfs_mount_options => $cinder_nfs_mount_options,
|
||||
nfs_shares_config => '/etc/cinder/shares-nfs.conf',
|
||||
nfs_snapshot_support => $cinder_nfs_snapshot_support,
|
||||
nas_secure_file_operations => $cinder_nas_secure_file_operations,
|
||||
nas_secure_file_permissions => $cinder_nas_secure_file_permissions,
|
||||
}
|
||||
|
@ -0,0 +1,5 @@
|
||||
---
|
||||
features:
|
||||
- |
|
||||
Add the ability to configure the nfs_snapshot_support parameter associated
|
||||
with Cinder's NFS backend.
|
@ -45,9 +45,12 @@ describe 'tripleo::profile::base::cinder::volume::nfs' do
|
||||
context 'with defaults' do
|
||||
it 'should trigger complete configuration' do
|
||||
is_expected.to contain_cinder__backend__nfs('tripleo_nfs').with(
|
||||
:nfs_servers => ['127.0.0.1'],
|
||||
:nfs_mount_options => '',
|
||||
:nfs_shares_config => '/etc/cinder/shares-nfs.conf'
|
||||
:nfs_servers => ['127.0.0.1'],
|
||||
:nfs_mount_options => '',
|
||||
:nfs_shares_config => '/etc/cinder/shares-nfs.conf',
|
||||
:nfs_snapshot_support => '<SERVICE DEFAULT>',
|
||||
:nas_secure_file_operations => '<SERVICE DEFAULT>',
|
||||
:nas_secure_file_permissions => '<SERVICE DEFAULT>',
|
||||
)
|
||||
end
|
||||
end
|
||||
@ -56,12 +59,18 @@ describe 'tripleo::profile::base::cinder::volume::nfs' do
|
||||
before :each do
|
||||
params.merge!(
|
||||
{
|
||||
:backend_availability_zone => 'my_zone',
|
||||
:backend_availability_zone => 'my_zone',
|
||||
:cinder_nfs_snapshot_support => 'true',
|
||||
:cinder_nas_secure_file_operations => 'false',
|
||||
:cinder_nas_secure_file_permissions => 'auto',
|
||||
})
|
||||
end
|
||||
it 'should trigger complete configuration' do
|
||||
is_expected.to contain_cinder__backend__nfs('tripleo_nfs').with(
|
||||
:backend_availability_zone => 'my_zone',
|
||||
:backend_availability_zone => 'my_zone',
|
||||
:nfs_snapshot_support => 'true',
|
||||
:nas_secure_file_operations => 'false',
|
||||
:nas_secure_file_permissions => 'auto',
|
||||
)
|
||||
end
|
||||
end
|
||||
|
Loading…
x
Reference in New Issue
Block a user