Add support to set host param
Lets expose this param so we can override the host param in ceilometer config. Without this, some metrics from nova wont make it as in some cases the fqdn might not match hostname. Partial-bug: #1721054 Change-Id: I421a61dc31bd10fec0a10bf7e867001cf4dd3f02
This commit is contained in:
parent
b30a0359ab
commit
4a249ae38c
@ -217,6 +217,12 @@
|
||||
# in the ceilometer config.
|
||||
# Defaults to false.
|
||||
#
|
||||
# [*host*]
|
||||
# (Optional) Name of this node. This is typically a hostname, FQDN, or
|
||||
# IP address.
|
||||
# Defaults to $::os_service_default.
|
||||
#
|
||||
#
|
||||
# === DEPRECATED PARAMETERS:
|
||||
# [*metering_secret*]
|
||||
# (optional) Secret key for signing messages.
|
||||
@ -310,6 +316,7 @@ class ceilometer(
|
||||
$snmpd_readonly_username = $::os_service_default,
|
||||
$snmpd_readonly_user_password = $::os_service_default,
|
||||
$purge_config = false,
|
||||
$host = $::os_service_default,
|
||||
# DEPRECATED PARAMETERS
|
||||
$alarm_history_time_to_live = undef,
|
||||
$metering_secret = undef,
|
||||
@ -435,6 +442,7 @@ please use memcache_servers instead.")
|
||||
# Once we got here, we can act as an honey badger on the rpc used.
|
||||
ceilometer_config {
|
||||
'DEFAULT/http_timeout' : value => $http_timeout;
|
||||
'DEFAULT/host' : value => $host;
|
||||
'publisher/telemetry_secret' : value => $telemetry_secret_real, secret => true;
|
||||
'database/event_time_to_live' : value => $event_time_to_live;
|
||||
'database/metering_time_to_live' : value => $metering_time_to_live;
|
||||
|
@ -0,0 +1,5 @@
|
||||
---
|
||||
fixes:
|
||||
- |
|
||||
Add support to override host param in ceilometer config. Without this
|
||||
sometimes fqdn wont match and some nova metrics will be skipped.
|
@ -13,6 +13,7 @@ describe 'ceilometer' do
|
||||
:log_dir => '/var/log/ceilometer',
|
||||
:use_stderr => 'True',
|
||||
:purge_config => false,
|
||||
:host => 'foo.domain'
|
||||
}
|
||||
end
|
||||
|
||||
@ -37,6 +38,10 @@ describe 'ceilometer' do
|
||||
is_expected.to contain_ceilometer_config('DEFAULT/http_timeout').with_value(params[:http_timeout])
|
||||
end
|
||||
|
||||
it 'configures host name' do
|
||||
is_expected.to contain_ceilometer_config('DEFAULT/host').with_value(params[:host])
|
||||
end
|
||||
|
||||
context 'with rabbit_host parameter' do
|
||||
before { params.merge!( rabbit_params ) }
|
||||
it_configures 'a ceilometer base installation'
|
||||
|
Loading…
Reference in New Issue
Block a user