tripleo-heat-templates/environments/metrics/collectd-read-rabbitmq.yaml
Takashi Kajinami ff83505e8a Replace hiera by lookup
The hiera function is deprecated and does not work with the latest
hieradata version 5. It should be replaced by the new lookup
function[1].

[1] https://puppet.com/docs/puppet/7/hiera_automatic.html

With the lookup function, we can define value type and merge behavior,
but these are kept default at this moment to limit scope of this change
to just simple replacement. Adding value type might be useful to make
sure the value is in expected type (especially when a boolean value is
expected), but we will revisit that later.

example:
lookup(<NAME>, [<VALUE TYPE>], [<MERGE BEHAVIOR>], [<DEFAULT VALUE>])

Change-Id: If5ac88ffccc1bb800d8af33c8896294a57e9b5fb
2022-04-14 17:07:52 +09:00

16 lines
588 B
YAML

# This environment file serves for enabling python-collect-rabbitmq and configuring
# it to monitor overcloud RabbitMQ instance
parameter_defaults:
ControllerExtraConfig:
tripleo::profile::base::metrics::collectd::python_read_plugins:
- python-collectd-rabbitmq
collectd::plugin::python::modules:
collectd_rabbitmq_monitoring:
config:
- host: "%{lookup('rabbitmq::interface')}"
port: "%{lookup('rabbitmq::port')}"
username: "%{lookup('rabbitmq::default_user')}"
password: "%{lookup('rabbitmq::default_pass')}"