Browse Source

Add ssl to oslo_messaging_amqp options

Change-Id: I14251f9ebeae55c4b696162d8241c4e56ea125ca
changes/51/454851/2 11.0.0
Andrew Smith 5 years ago
parent
commit
e05dd0e477
  1. 6
      manifests/messaging/amqp.pp
  2. 3
      spec/defines/oslo_messaging_amqp_spec.rb

6
manifests/messaging/amqp.pp

@ -69,6 +69,10 @@
# (Optional) Debug: dump AMQP frames to stdout
# Defaults to $::os_service_default.
#
# [*ssl*]
# (Optional) Attempt to connect via SSL.
# Defaults to $::os_service_default.
#
# [*ssl_ca_file*]
# (Optional) CA certificate PEM file to verify server certificate
# Defaults to $::os_service_default.
@ -133,6 +137,7 @@ define oslo::messaging::amqp(
$container_name = $::os_service_default,
$idle_timeout = $::os_service_default,
$trace = $::os_service_default,
$ssl = $::os_service_default,
$ssl_ca_file = $::os_service_default,
$ssl_cert_file = $::os_service_default,
$ssl_key_file = $::os_service_default,
@ -161,6 +166,7 @@ define oslo::messaging::amqp(
'oslo_messaging_amqp/container_name' => { value => $container_name },
'oslo_messaging_amqp/idle_timeout' => { value => $idle_timeout },
'oslo_messaging_amqp/trace' => { value => $trace },
'oslo_messaging_amqp/ssl' => { value => $ssl },
'oslo_messaging_amqp/ssl_ca_file' => { value => $ssl_ca_file },
'oslo_messaging_amqp/ssl_cert_file' => { value => $ssl_cert_file },
'oslo_messaging_amqp/ssl_key_file' => { value => $ssl_key_file },

3
spec/defines/oslo_messaging_amqp_spec.rb

@ -23,6 +23,7 @@ describe 'oslo::messaging::amqp' do
is_expected.to contain_keystone_config('oslo_messaging_amqp/container_name').with_value('<SERVICE DEFAULT>')
is_expected.to contain_keystone_config('oslo_messaging_amqp/idle_timeout').with_value('<SERVICE DEFAULT>')
is_expected.to contain_keystone_config('oslo_messaging_amqp/trace').with_value('<SERVICE DEFAULT>')
is_expected.to contain_keystone_config('oslo_messaging_amqp/ssl').with_value('<SERVICE DEFAULT>')
is_expected.to contain_keystone_config('oslo_messaging_amqp/ssl_ca_file').with_value('<SERVICE DEFAULT>')
is_expected.to contain_keystone_config('oslo_messaging_amqp/ssl_cert_file').with_value('<SERVICE DEFAULT>')
is_expected.to contain_keystone_config('oslo_messaging_amqp/ssl_key_file').with_value('<SERVICE DEFAULT>')
@ -46,6 +47,7 @@ describe 'oslo::messaging::amqp' do
:username => 'newuser',
:password => 'p@ssw0rd',
:pre_settled => ['rpc-cast','rpc-reply','notify'],
:ssl => true,
}
end
it 'configure oslo_messaging_amqp with overriden values' do
@ -54,6 +56,7 @@ describe 'oslo::messaging::amqp' do
is_expected.to contain_keystone_config('oslo_messaging_amqp/username').with_value('newuser')
is_expected.to contain_keystone_config('oslo_messaging_amqp/password').with_value('p@ssw0rd').with_secret(true)
is_expected.to contain_keystone_config('oslo_messaging_amqp/pre_settled').with_value(['rpc-cast','rpc-reply','notify'])
is_expected.to contain_keystone_config('oslo_messaging_amqp/ssl').with_value(true)
end
end

Loading…
Cancel
Save