f0371cecf2
This change replaces current implementation to manage packages for coordination backend by oslo::coordination resource type, so that we can gather all logics related to coordination in a single place. Because Gnocchi is not using a common parameter name, configuration is still managed by gnocchi class. Depends-on: https://review.opendev.org/792535 Change-Id: I9998d1351ec656fd2e4c0eee8de16f4c65d1aeb8
46 lines
1.0 KiB
Puppet
46 lines
1.0 KiB
Puppet
# == Class: gnocchi
|
|
#
|
|
# Full description of class gnocchi here.
|
|
#
|
|
# === Parameters
|
|
#
|
|
# [*package_ensure*]
|
|
# (optional) The state of gnocchi packages
|
|
# Defaults to 'present'
|
|
#
|
|
# [*coordination_url*]
|
|
# (optional) The url to use for distributed group membership coordination.
|
|
# Defaults to $::os_service_default.
|
|
#
|
|
# [*purge_config*]
|
|
# (optional) Whether to set only the specified config options
|
|
# in the gnocchi config.
|
|
# Defaults to false.
|
|
#
|
|
class gnocchi (
|
|
$package_ensure = 'present',
|
|
$coordination_url = $::os_service_default,
|
|
$purge_config = false,
|
|
) inherits gnocchi::params {
|
|
|
|
include gnocchi::deps
|
|
|
|
package { 'gnocchi':
|
|
ensure => $package_ensure,
|
|
name => $::gnocchi::params::common_package_name,
|
|
tag => ['openstack', 'gnocchi-package'],
|
|
}
|
|
|
|
resources { 'gnocchi_config':
|
|
purge => $purge_config,
|
|
}
|
|
|
|
oslo::coordination{ 'gnocchi_config':
|
|
backend_url => $coordination_url,
|
|
manage_config => false,
|
|
}
|
|
gnocchi_config {
|
|
'DEFAULT/coordination_url' : value => $coordination_url;
|
|
}
|
|
}
|