diff --git a/manifests/proxy/ceilometer.pp b/manifests/proxy/ceilometer.pp index b8dfcd31..3de6375b 100644 --- a/manifests/proxy/ceilometer.pp +++ b/manifests/proxy/ceilometer.pp @@ -39,6 +39,42 @@ # Whether to send events to messaging driver in a background thread # Defaults to false # +# [*ignore_projects*] +# What projects to ignore to send events to ceilometer +# Defaults to ['services'] +# +# [*auth_uri*] +# (Optional) Complete public Identity API endpoint. +# Defaults to 'http://127.0.0.1:5000' +# +# [*auth_url*] +# (Optional) The URL to use for authentication. +# Defaults to 'http://127.0.0.1:35357' +# +# [*auth_type*] +# (Optional) The plugin for authentication +# Defaults to 'password' +# +# [*project_name*] +# (Optional) Service project name +# Defaults to 'services' +# +# [*project_domain_name*] +# (Optional) name of domain for $project_name +# Defaults to 'default' +# +# [*user_domain_name*] +# (Optional) name of domain for $username +# Defaults to 'default' +# +# [*username*] +# (Optional) The name of the service user +# Defaults to 'swift' +# +# [*password*] +# (Optional) The password for the user +# Defaults to 'password' +# # === DEPRECATED PARAMETERS # # [*rabbit_host*] @@ -84,6 +120,15 @@ class swift::proxy::ceilometer( $ensure = 'present', $group = 'ceilometer', $nonblocking_notify = false, + $ignore_projects = ['services'], + $auth_uri = 'http://127.0.0.1:5000', + $auth_url = 'http://127.0.0.1:35357', + $auth_type = 'password', + $project_domain_name = 'Default', + $user_domain_name = 'Default', + $project_name = 'services', + $username = 'swift', + $password = 'password', # DEPRECATED PARAMETERS $rabbit_user = 'guest', $rabbit_password = 'guest', @@ -139,6 +184,15 @@ deprecated. Please use swift::proxy::ceilometer::default_transport_url instead." 'filter:ceilometer/control_exchange': value => $control_exchange; 'filter:ceilometer/paste.filter_factory': value => 'ceilometermiddleware.swift:filter_factory'; 'filter:ceilometer/nonblocking_notify': value => $nonblocking_notify; + 'filter:ceilometer/ignore_projects': value => $ignore_projects; + 'filter:ceilometer/auth_uri': value => $auth_uri; + 'filter:ceilometer/auth_url': value => $auth_url; + 'filter:ceilometer/auth_type': value => $auth_type; + 'filter:ceilometer/project_domain_name': value => $project_domain_name; + 'filter:ceilometer/user_domain_name': value => $user_domain_name; + 'filter:ceilometer/project_name': value => $project_name; + 'filter:ceilometer/username': value => $username; + 'filter:ceilometer/password': value => $password; } package { 'python-ceilometermiddleware': diff --git a/releasenotes/notes/add-ignore-projects-b1ab3629320a39ed.yaml b/releasenotes/notes/add-ignore-projects-b1ab3629320a39ed.yaml new file mode 100644 index 00000000..4feeb1a3 --- /dev/null +++ b/releasenotes/notes/add-ignore-projects-b1ab3629320a39ed.yaml @@ -0,0 +1,3 @@ +--- +fixes: + - Add ignore projects setting to filter:ceilometer in proxy server config. diff --git a/spec/classes/swift_proxy_ceilometer_spec.rb b/spec/classes/swift_proxy_ceilometer_spec.rb index 44f408ef..aeb5ebaa 100644 --- a/spec/classes/swift_proxy_ceilometer_spec.rb +++ b/spec/classes/swift_proxy_ceilometer_spec.rb @@ -32,6 +32,15 @@ describe 'swift::proxy::ceilometer' do :topic => 'notifications', :control_exchange => 'swift', :nonblocking_notify => true, + :ignore_projects => ['services'], + :auth_uri => 'http://127.0.0.1:5000', + :auth_url => 'http://127.0.0.1:35357', + :auth_type => 'password', + :project_domain_name => 'Default', + :user_domain_name => 'Default', + :project_name => 'services', + :username => 'swift', + :password => 'password', } end @@ -43,6 +52,15 @@ describe 'swift::proxy::ceilometer' do it { is_expected.to contain_swift_proxy_config('filter:ceilometer/topic').with_value('notifications') } it { is_expected.to contain_swift_proxy_config('filter:ceilometer/control_exchange').with_value('swift') } it { is_expected.to contain_swift_proxy_config('filter:ceilometer/nonblocking_notify').with_value('true') } + it { is_expected.to contain_swift_proxy_config('filter:ceilometer/ignore_projects').with_value(['services']) } + it { is_expected.to contain_swift_proxy_config('filter:ceilometer/auth_uri').with_value('http://127.0.0.1:5000') } + it { is_expected.to contain_swift_proxy_config('filter:ceilometer/auth_url').with_value('http://127.0.0.1:35357') } + it { is_expected.to contain_swift_proxy_config('filter:ceilometer/auth_type').with_value('password') } + it { is_expected.to contain_swift_proxy_config('filter:ceilometer/project_domain_name').with_value('Default') } + it { is_expected.to contain_swift_proxy_config('filter:ceilometer/user_domain_name').with_value('Default') } + it { is_expected.to contain_swift_proxy_config('filter:ceilometer/project_name').with_value('services') } + it { is_expected.to contain_swift_proxy_config('filter:ceilometer/username').with_value('swift') } + it { is_expected.to contain_swift_proxy_config('filter:ceilometer/password').with_value('password') } end context 'with multiple rabbit hosts' do