Merge "Add the enable_new_services option to nova::conductor"
This commit is contained in:
@@ -20,6 +20,13 @@
|
|||||||
# (optional) Number of workers for OpenStack Conductor service
|
# (optional) Number of workers for OpenStack Conductor service
|
||||||
# Defaults to undef (i.e. parameter will not be present)
|
# Defaults to undef (i.e. parameter will not be present)
|
||||||
#
|
#
|
||||||
|
# [*enable_new_services*]
|
||||||
|
# (optional) When a new service (for example "nova-compute") start up, it gets
|
||||||
|
# registered in the database as an enabled service. Setting this to false will
|
||||||
|
# cause new services to be disabled when added. This config option is only used
|
||||||
|
# by the conductor service which is responsible for creating the service entries.
|
||||||
|
# Defaults to $::os_service_default
|
||||||
|
#
|
||||||
# DEPRECATED PARAMETERS
|
# DEPRECATED PARAMETERS
|
||||||
#
|
#
|
||||||
# [*use_local*]
|
# [*use_local*]
|
||||||
@@ -27,12 +34,13 @@
|
|||||||
# Defaults to undef
|
# Defaults to undef
|
||||||
#
|
#
|
||||||
class nova::conductor(
|
class nova::conductor(
|
||||||
$enabled = true,
|
$enabled = true,
|
||||||
$manage_service = true,
|
$manage_service = true,
|
||||||
$ensure_package = 'present',
|
$ensure_package = 'present',
|
||||||
$workers = undef,
|
$workers = undef,
|
||||||
|
$enable_new_services = $::os_service_default,
|
||||||
# DEPREACTED PARAMETERS
|
# DEPREACTED PARAMETERS
|
||||||
$use_local = undef,
|
$use_local = undef,
|
||||||
) {
|
) {
|
||||||
|
|
||||||
if $use_local {
|
if $use_local {
|
||||||
@@ -56,4 +64,8 @@ class nova::conductor(
|
|||||||
'conductor/workers': value => $workers;
|
'conductor/workers': value => $workers;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
nova_config {
|
||||||
|
'DEFAULT/enable_new_services': value => $enable_new_services
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@@ -0,0 +1,3 @@
|
|||||||
|
---
|
||||||
|
features:
|
||||||
|
- Adds the enable_new_services config parameter to nova conductor
|
@@ -46,6 +46,18 @@ describe 'nova::conductor' do
|
|||||||
it { is_expected.to contain_nova_config('conductor/workers').with_value('5') }
|
it { is_expected.to contain_nova_config('conductor/workers').with_value('5') }
|
||||||
end
|
end
|
||||||
|
|
||||||
|
context 'with default enable_new_services parameter' do
|
||||||
|
it { is_expected.to contain_nova_config('DEFAULT/enable_new_services').with_value('<SERVICE DEFAULT>') }
|
||||||
|
end
|
||||||
|
|
||||||
|
context 'with enable_new_services parameter set to false' do
|
||||||
|
let :params do
|
||||||
|
{ :enable_new_services => false }
|
||||||
|
end
|
||||||
|
|
||||||
|
it { is_expected.to contain_nova_config('DEFAULT/enable_new_services').with_value(false) }
|
||||||
|
end
|
||||||
|
|
||||||
context 'with default database parameters' do
|
context 'with default database parameters' do
|
||||||
let :pre_condition do
|
let :pre_condition do
|
||||||
"include nova"
|
"include nova"
|
||||||
|
Reference in New Issue
Block a user