Make swift_service_type configurable in guestagent.conf
Change-Id: Id167b0dcf68fc6d9b211ecb9c6acbfaf4b1afead Closes-Bug: #1569658
This commit is contained in:
parent
36263dc353
commit
3cb02d8768
@ -47,6 +47,10 @@
|
||||
# lookup the URL using the Keystone catalog.
|
||||
# Defaults to $::os_service_default.
|
||||
#
|
||||
# [*swift_service_type*]
|
||||
# (optional) Service type to use when searching catalog
|
||||
# Defaults to $::os_service_default.
|
||||
#
|
||||
# [*rabbit_hosts*]
|
||||
# (optional) List of clustered rabbit servers.
|
||||
# Defaults to the value set in the trove class.
|
||||
@ -109,6 +113,7 @@ class trove::guestagent(
|
||||
$log_facility = $::os_service_default,
|
||||
$auth_url = 'http://localhost:5000/v2.0',
|
||||
$swift_url = $::os_service_default,
|
||||
$swift_service_type = $::os_service_default,
|
||||
$rabbit_hosts = $::trove::rabbit_hosts,
|
||||
$rabbit_host = $::trove::rabbit_host,
|
||||
$rabbit_port = $::trove::rabbit_port,
|
||||
@ -130,11 +135,12 @@ class trove::guestagent(
|
||||
|
||||
# basic service config
|
||||
trove_guestagent_config {
|
||||
'DEFAULT/trove_auth_url': value => $auth_url;
|
||||
'DEFAULT/swift_url': value => $swift_url;
|
||||
'DEFAULT/root_grant': value => $root_grant;
|
||||
'DEFAULT/root_grant_option': value => $root_grant_option;
|
||||
'DEFAULT/default_password_length': value => $default_password_length;
|
||||
'DEFAULT/trove_auth_url': value => $auth_url;
|
||||
'DEFAULT/swift_url': value => $swift_url;
|
||||
'DEFAULT/swift_service_type': value => $swift_service_type;
|
||||
'DEFAULT/root_grant': value => $root_grant;
|
||||
'DEFAULT/root_grant_option': value => $root_grant_option;
|
||||
'DEFAULT/default_password_length': value => $default_password_length;
|
||||
}
|
||||
|
||||
oslo::messaging::default { 'trove_guestagent_config':
|
||||
|
@ -0,0 +1,3 @@
|
||||
---
|
||||
features:
|
||||
- Add ability to configure swift_service_type in guestagent.conf.
|
@ -48,6 +48,7 @@ describe 'trove::guestagent' do
|
||||
is_expected.to contain_trove_guestagent_config('oslo_messaging_rabbit/kombu_reconnect_delay').with_value('<SERVICE DEFAULT>')
|
||||
is_expected.to contain_trove_guestagent_config('oslo_messaging_rabbit/amqp_durable_queues').with_value('<SERVICE DEFAULT>')
|
||||
is_expected.to contain_trove_guestagent_config('DEFAULT/swift_url').with_value('<SERVICE DEFAULT>')
|
||||
is_expected.to contain_trove_guestagent_config('DEFAULT/swift_service_type').with_value('<SERVICE DEFAULT>')
|
||||
is_expected.to contain_trove_guestagent_config('DEFAULT/root_grant').with_value('<SERVICE DEFAULT>')
|
||||
is_expected.to contain_trove_guestagent_config('DEFAULT/root_grant_option').with_value('<SERVICE DEFAULT>')
|
||||
is_expected.to contain_trove_guestagent_config('DEFAULT/default_password_length').with_value('<SERVICE DEFAULT>')
|
||||
@ -104,6 +105,7 @@ describe 'trove::guestagent' do
|
||||
let :params do
|
||||
{ :auth_url => "http://10.0.0.1:5000/v2.0",
|
||||
:swift_url => "http://10.0.0.1:8080/v1/AUTH_",
|
||||
:swift_service_type => 'object-store',
|
||||
:rabbit_host => '10.1.0.1',
|
||||
:rabbit_port => '5673',
|
||||
:rabbit_use_ssl => 'true'
|
||||
@ -112,6 +114,7 @@ describe 'trove::guestagent' do
|
||||
it 'configures trove-guestagent with custom parameters' do
|
||||
is_expected.to contain_trove_guestagent_config('DEFAULT/trove_auth_url').with_value('http://10.0.0.1:5000/v2.0')
|
||||
is_expected.to contain_trove_guestagent_config('DEFAULT/swift_url').with_value('http://10.0.0.1:8080/v1/AUTH_')
|
||||
is_expected.to contain_trove_guestagent_config('DEFAULT/swift_service_type').with_value('object-store')
|
||||
is_expected.to contain_trove_guestagent_config('oslo_messaging_rabbit/rabbit_host').with_value('10.1.0.1')
|
||||
is_expected.to contain_trove_guestagent_config('oslo_messaging_rabbit/rabbit_port').with_value('5673')
|
||||
is_expected.to contain_trove_guestagent_config('oslo_messaging_rabbit/rabbit_use_ssl').with_value('true')
|
||||
|
Loading…
Reference in New Issue
Block a user