Add oslo_messaging_notifications transport_url
Adding the ability to configure the oslo_messaging_notifications transport_url. Change-Id: Ia94e8df7fdc8bf0450c6038e46369d88adb6c608
This commit is contained in:
parent
0328890f7d
commit
a7695e4a34
|
@ -52,6 +52,11 @@
|
|||
# transport://user:pass@host1:port[,hostN:portN]/virtual_host
|
||||
# Defaults to $::os_service_default
|
||||
#
|
||||
# [*notification_transport_url*]
|
||||
# (optional) Connection url for oslo messaging notification backend. An
|
||||
# example rabbit url would be, rabbit://user:pass@host:port/virtual_host
|
||||
# Defaults to $::os_service_default
|
||||
#
|
||||
# [*rabbit_use_ssl*]
|
||||
# (optional) Connect over SSL for RabbitMQ
|
||||
# Defaults to false
|
||||
|
@ -130,26 +135,27 @@
|
|||
# Defaults to $::os_service_default
|
||||
#
|
||||
class designate(
|
||||
$package_ensure = present,
|
||||
$common_package_name = $::designate::params::common_package_name,
|
||||
$debug = undef,
|
||||
$log_dir = undef,
|
||||
$use_syslog = undef,
|
||||
$use_stderr = undef,
|
||||
$log_facility = undef,
|
||||
$root_helper = 'sudo designate-rootwrap /etc/designate/rootwrap.conf',
|
||||
$rpc_backend = 'rabbit',
|
||||
$default_transport_url = $::os_service_default,
|
||||
$rabbit_use_ssl = false,
|
||||
$rabbit_ha_queues = $::os_service_default,
|
||||
$kombu_ssl_ca_certs = $::os_service_default,
|
||||
$kombu_ssl_certfile = $::os_service_default,
|
||||
$kombu_ssl_keyfile = $::os_service_default,
|
||||
$kombu_ssl_version = $::os_service_default,
|
||||
$kombu_reconnect_delay = $::os_service_default,
|
||||
$notification_driver = 'messaging',
|
||||
$notification_topics = 'notifications',
|
||||
$purge_config = false,
|
||||
$package_ensure = present,
|
||||
$common_package_name = $::designate::params::common_package_name,
|
||||
$debug = undef,
|
||||
$log_dir = undef,
|
||||
$use_syslog = undef,
|
||||
$use_stderr = undef,
|
||||
$log_facility = undef,
|
||||
$root_helper = 'sudo designate-rootwrap /etc/designate/rootwrap.conf',
|
||||
$rpc_backend = 'rabbit',
|
||||
$notification_transport_url = $::os_service_default,
|
||||
$rabbit_use_ssl = false,
|
||||
$rabbit_ha_queues = $::os_service_default,
|
||||
$kombu_ssl_ca_certs = $::os_service_default,
|
||||
$kombu_ssl_certfile = $::os_service_default,
|
||||
$kombu_ssl_keyfile = $::os_service_default,
|
||||
$kombu_ssl_version = $::os_service_default,
|
||||
$kombu_reconnect_delay = $::os_service_default,
|
||||
$notification_driver = 'messaging',
|
||||
$default_transport_url = $::os_service_default,
|
||||
$notification_topics = 'notifications',
|
||||
$purge_config = false,
|
||||
#DEPRECATED PARAMETER
|
||||
$rabbit_virtualhost = undef,
|
||||
$rabbit_host = $::os_service_default,
|
||||
|
@ -247,12 +253,16 @@ to your desired configuration.")
|
|||
transport_url => $default_transport_url,
|
||||
}
|
||||
|
||||
oslo::messaging::notifications { 'designate_config':
|
||||
driver => $notification_driver,
|
||||
transport_url => $notification_transport_url,
|
||||
topics => $notification_topics,
|
||||
}
|
||||
|
||||
# default setting
|
||||
designate_config {
|
||||
'DEFAULT/root_helper' : value => $root_helper;
|
||||
'DEFAULT/state_path' : value => $::designate::params::state_path;
|
||||
'DEFAULT/notification_driver' : value => $notification_driver;
|
||||
'DEFAULT/notification_topics' : value => $notification_topics;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -0,0 +1,4 @@
|
|||
---
|
||||
features:
|
||||
- Add the ability to configure the oslo messaging notification transport url
|
||||
via designate::notficiation_transport_url
|
|
@ -135,8 +135,10 @@ describe 'designate' do
|
|||
end
|
||||
|
||||
it 'configures notification' do
|
||||
is_expected.to contain_designate_config('DEFAULT/notification_driver').with_value('messaging' )
|
||||
is_expected.to contain_designate_config('DEFAULT/notification_topics').with_value('notifications')
|
||||
is_expected.to contain_designate_config('oslo_messaging_notifications/driver').with_value('messaging' )
|
||||
is_expected.to contain_designate_config('oslo_messaging_notifications/topics').with_value('notifications')
|
||||
is_expected.to contain_designate_config('oslo_messaging_notifications/transport_url').with_value('<SERVICE DEFAULT>')
|
||||
is_expected.to contain_designate_config('DEFAULT/transport_url').with_value('<SERVICE DEFAULT>')
|
||||
end
|
||||
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue