Add endpoint_type options
Add trove::nova_compute_endpoint_type, trove::neutron_endpoint_type, trove::glance_endpoint_type, trove::cinder_endpoint_type, trove::swift_endpoint_type, trove::trove_endpoint_type options to configure endpoint type to use when searching catalog. Change-Id: Iba9d4033d4b5267c4b2a326499364ac44d89400a
This commit is contained in:
parent
d33c0265c9
commit
0763133219
@ -268,6 +268,16 @@ the future release. Please use trove::api::package_ensure instead.")
|
||||
'DEFAULT/swift_service_type': value => $::trove::swift_service_type;
|
||||
}
|
||||
|
||||
# endpoint type
|
||||
trove_config {
|
||||
'DEFAULT/nova_compute_endpoint_type': value => $::trove::nova_compute_endpoint_type;
|
||||
'DEFAULT/cinder_endpoint_type': value => $::trove::cinder_endpoint_type;
|
||||
'DEFAULT/neutron_endpoint_type': value => $::trove::neutron_endpoint_type;
|
||||
'DEFAULT/swift_endpoint_type': value => $::trove::swift_endpoint_type;
|
||||
'DEFAULT/glance_endpoint_type': value => $::trove::glance_endpoint_type;
|
||||
'DEFAULT/trove_endpoint_type': value => $::trove::trove_endpoint_type;
|
||||
}
|
||||
|
||||
if $::trove::use_neutron {
|
||||
trove_config {
|
||||
'DEFAULT/network_label_regex': value => '.*';
|
||||
|
@ -244,6 +244,30 @@
|
||||
# (optional) Neutron service type to use when searching catalog.
|
||||
# Defaults to 'network'.
|
||||
#
|
||||
# [*nova_compute_endpoint_type*]
|
||||
# (optional) Service endpoint type to use when searching catalog.
|
||||
# Defaults to $::os_service_default
|
||||
#
|
||||
# [*neutron_endpoint_type*]
|
||||
# (optional) Service endpoint type to use when searching catalog.
|
||||
# Defaults to $::os_service_default
|
||||
#
|
||||
# [*cinder_endpoint_type*]
|
||||
# (optional) Service endpoint type to use when searching catalog.
|
||||
# Defaults to $::os_service_default
|
||||
#
|
||||
# [*swift_endpoint_type*]
|
||||
# (optional) Service endpoint type to use when searching catalog.
|
||||
# Defaults to $::os_service_default
|
||||
#
|
||||
# [*glance_endpoint_type*]
|
||||
# (optional) Service endpoint type to use when searching catalog.
|
||||
# Defaults to $::os_service_default
|
||||
#
|
||||
# [*trove_endpoint_type*]
|
||||
# (optional) Service endpoint type to use when searching catalog.
|
||||
# Defaults to $::os_service_default
|
||||
#
|
||||
# [*use_neutron*]
|
||||
# (optional) Use Neutron
|
||||
# Defaults to true
|
||||
@ -351,6 +375,12 @@ class trove(
|
||||
$cinder_service_type = 'volumev2',
|
||||
$swift_service_type = 'object-store',
|
||||
$neutron_service_type = 'network',
|
||||
$nova_compute_endpoint_type = $::os_service_default,
|
||||
$cinder_endpoint_type = $::os_service_default,
|
||||
$swift_endpoint_type = $::os_service_default,
|
||||
$glance_endpoint_type = $::os_service_default,
|
||||
$trove_endpoint_type = $::os_service_default,
|
||||
$neutron_endpoint_type = $::os_service_default,
|
||||
$use_neutron = true,
|
||||
$default_neutron_networks = $::os_service_default,
|
||||
$package_ensure = 'present',
|
||||
|
@ -175,6 +175,16 @@ the future release. Please use trove::default_neutron_networks instead.")
|
||||
'DEFAULT/swift_service_type': value => $::trove::swift_service_type;
|
||||
}
|
||||
|
||||
# endpoint type
|
||||
trove_taskmanager_config {
|
||||
'DEFAULT/nova_compute_endpoint_type': value => $::trove::nova_compute_endpoint_type;
|
||||
'DEFAULT/cinder_endpoint_type': value => $::trove::cinder_endpoint_type;
|
||||
'DEFAULT/neutron_endpoint_type': value => $::trove::neutron_endpoint_type;
|
||||
'DEFAULT/swift_endpoint_type': value => $::trove::swift_endpoint_type;
|
||||
'DEFAULT/glance_endpoint_type': value => $::trove::glance_endpoint_type;
|
||||
'DEFAULT/trove_endpoint_type': value => $::trove::trove_endpoint_type;
|
||||
}
|
||||
|
||||
if $::trove::single_tenant_mode {
|
||||
trove_taskmanager_config {
|
||||
'DEFAULT/remote_nova_client': value => 'trove.common.single_tenant_remote.nova_client_trove_admin';
|
||||
|
@ -0,0 +1,6 @@
|
||||
---
|
||||
features:
|
||||
- Add trove::nova_compute_endpoint_type, trove::neutron_endpoint_type,
|
||||
trove::glance_endpoint_type, trove::cinder_endpoint_type,
|
||||
trove::swift_endpoint_type, trove::trove_endpoint_type options to
|
||||
configure endpoint type to use when searching catalog.
|
@ -31,12 +31,19 @@ describe 'trove::api' do
|
||||
|
||||
let :pre_condition do
|
||||
"class { 'trove':
|
||||
nova_proxy_admin_pass => 'verysecrete',
|
||||
os_region_name => 'RegionOne',
|
||||
nova_compute_service_type => 'compute',
|
||||
cinder_service_type => 'volume',
|
||||
swift_service_type => 'object-store',
|
||||
neutron_service_type => 'network'}
|
||||
nova_proxy_admin_pass => 'verysecrete',
|
||||
os_region_name => 'RegionOne',
|
||||
nova_compute_service_type => 'compute',
|
||||
cinder_service_type => 'volume',
|
||||
swift_service_type => 'object-store',
|
||||
neutron_service_type => 'network',
|
||||
nova_compute_endpoint_type => '<SERVICE DEFAULT>',
|
||||
cinder_endpoint_type => '<SERVICE DEFAULT>',
|
||||
swift_endpoint_type => '<SERVICE DEFAULT>',
|
||||
trove_endpoint_type => '<SERVICE DEFAULT>',
|
||||
glance_endpoint_type => '<SERVICE DEFAULT>',
|
||||
neutron_endpoint_type => '<SERVICE DEFAULT>',
|
||||
}
|
||||
class { '::trove::keystone::authtoken':
|
||||
password => 'a_big_secret',
|
||||
}"
|
||||
@ -72,6 +79,12 @@ describe 'trove::api' do
|
||||
is_expected.to contain_trove_config('DEFAULT/cinder_service_type').with_value('volume')
|
||||
is_expected.to contain_trove_config('DEFAULT/swift_service_type').with_value('object-store')
|
||||
is_expected.to contain_trove_config('DEFAULT/neutron_service_type').with_value('network')
|
||||
is_expected.to contain_trove_config('DEFAULT/nova_compute_endpoint_type').with_value('<SERVICE DEFAULT>')
|
||||
is_expected.to contain_trove_config('DEFAULT/cinder_endpoint_type').with_value('<SERVICE DEFAULT>')
|
||||
is_expected.to contain_trove_config('DEFAULT/swift_endpoint_type').with_value('<SERVICE DEFAULT>')
|
||||
is_expected.to contain_trove_config('DEFAULT/trove_endpoint_type').with_value('<SERVICE DEFAULT>')
|
||||
is_expected.to contain_trove_config('DEFAULT/neutron_endpoint_type').with_value('<SERVICE DEFAULT>')
|
||||
is_expected.to contain_trove_config('DEFAULT/glance_endpoint_type').with_value('<SERVICE DEFAULT>')
|
||||
is_expected.to contain_trove_config('DEFAULT/http_get_rate').with_value('200')
|
||||
is_expected.to contain_trove_config('DEFAULT/http_post_rate').with_value('200')
|
||||
is_expected.to contain_trove_config('DEFAULT/http_put_rate').with_value('200')
|
||||
|
@ -27,12 +27,19 @@ describe 'trove::taskmanager' do
|
||||
|
||||
let :pre_condition do
|
||||
"class { 'trove':
|
||||
nova_proxy_admin_pass => 'verysecrete',
|
||||
os_region_name => 'RegionOne',
|
||||
nova_compute_service_type => 'compute',
|
||||
cinder_service_type => 'volume',
|
||||
swift_service_type => 'object-store',
|
||||
neutron_service_type => 'network'}"
|
||||
nova_proxy_admin_pass => 'verysecrete',
|
||||
os_region_name => 'RegionOne',
|
||||
nova_compute_service_type => 'compute',
|
||||
cinder_service_type => 'volume',
|
||||
swift_service_type => 'object-store',
|
||||
neutron_service_type => 'network',
|
||||
nova_compute_endpoint_type => '<SERVICE DEFAULT>',
|
||||
cinder_endpoint_type => '<SERVICE DEFAULT>',
|
||||
swift_endpoint_type => '<SERVICE DEFAULT>',
|
||||
trove_endpoint_type => '<SERVICE DEFAULT>',
|
||||
glance_endpoint_type => '<SERVICE DEFAULT>',
|
||||
neutron_endpoint_type => '<SERVICE DEFAULT>',
|
||||
}"
|
||||
end
|
||||
|
||||
it 'installs trove-taskmanager package and service' do
|
||||
@ -59,6 +66,12 @@ describe 'trove::taskmanager' do
|
||||
is_expected.to contain_trove_taskmanager_config('DEFAULT/cinder_service_type').with_value('volume')
|
||||
is_expected.to contain_trove_taskmanager_config('DEFAULT/swift_service_type').with_value('object-store')
|
||||
is_expected.to contain_trove_taskmanager_config('DEFAULT/neutron_service_type').with_value('network')
|
||||
is_expected.to contain_trove_taskmanager_config('DEFAULT/nova_compute_endpoint_type').with_value('<SERVICE DEFAULT>')
|
||||
is_expected.to contain_trove_taskmanager_config('DEFAULT/cinder_endpoint_type').with_value('<SERVICE DEFAULT>')
|
||||
is_expected.to contain_trove_taskmanager_config('DEFAULT/swift_endpoint_type').with_value('<SERVICE DEFAULT>')
|
||||
is_expected.to contain_trove_taskmanager_config('DEFAULT/trove_endpoint_type').with_value('<SERVICE DEFAULT>')
|
||||
is_expected.to contain_trove_taskmanager_config('DEFAULT/neutron_endpoint_type').with_value('<SERVICE DEFAULT>')
|
||||
is_expected.to contain_trove_taskmanager_config('DEFAULT/glance_endpoint_type').with_value('<SERVICE DEFAULT>')
|
||||
is_expected.to contain_trove_taskmanager_config('DEFAULT/taskmanager_manager').with_value('trove.taskmanager.manager.Manager')
|
||||
is_expected.to contain_file('/etc/trove/trove-guestagent.conf')
|
||||
is_expected.to contain_trove_taskmanager_config('DEFAULT/transport_url').with_value('<SERVICE DEFAULT>')
|
||||
|
Loading…
x
Reference in New Issue
Block a user