Add purge_config option
Add the option in order to facilitate management. User can ensure that only the options they hoped are configured. Change-Id: I56816b0fc55566a5a74dc6c1a770081372b520f3
This commit is contained in:
@@ -179,6 +179,11 @@
|
||||
# (optional) Number of seconds between heartbeats for coordination.
|
||||
# Defaults to $::os_service_default
|
||||
#
|
||||
# [*purge_config*]
|
||||
# (optional) Whether to set only the specified config options
|
||||
# in the mistral config.
|
||||
# Defaults to false.
|
||||
#
|
||||
# DEPRECATED PARAMETERS
|
||||
#
|
||||
# [*verbose*]
|
||||
@@ -220,6 +225,7 @@ class mistral(
|
||||
$debug = undef,
|
||||
$coordination_backend_url = $::os_service_default,
|
||||
$coordination_heartbeat_interval = $::os_service_default,
|
||||
$purge_config = false,
|
||||
# Deprecated
|
||||
$verbose = undef,
|
||||
){
|
||||
@@ -236,6 +242,10 @@ class mistral(
|
||||
tag => ['openstack', 'mistral-package'],
|
||||
}
|
||||
|
||||
resources { 'mistral_config':
|
||||
purge => $purge_config,
|
||||
}
|
||||
|
||||
if $verbose {
|
||||
warning('verbose is deprecated, has no effect and will be removed after Newton cycle.')
|
||||
}
|
||||
|
@@ -4,6 +4,7 @@ describe 'mistral' do
|
||||
{
|
||||
:database_connection => 'mysql://user:password@host/database',
|
||||
:keystone_password => 'foo',
|
||||
:purge_config => false,
|
||||
}
|
||||
end
|
||||
|
||||
@@ -24,6 +25,12 @@ describe 'mistral' do
|
||||
it { is_expected.to contain_class('mistral::params') }
|
||||
it { is_expected.to contain_class('mysql::bindings::python') }
|
||||
|
||||
it 'passes purge to resource' do
|
||||
is_expected.to contain_resources('mistral_config').with({
|
||||
:purge => false
|
||||
})
|
||||
end
|
||||
|
||||
it 'should contain default config' do
|
||||
is_expected.to contain_mistral_config('DEFAULT/rpc_backend').with(:value => 'rabbit')
|
||||
is_expected.to contain_mistral_config('DEFAULT/control_exchange').with(:value => '<SERVICE DEFAULT>')
|
||||
|
Reference in New Issue
Block a user