Note: the 3 changes need to be in the same commit because CI is broken at
this time.
Change #1
In Mitaka gnocchi-dbsync was moved to gnocchi-upgrade [1,2].
[1] aee5df615e
[2] https://review.openstack.org/#/c/245069/5/setup.cfg
Partial-bug: #1535382
Change #2
drop mock dependency
mock is not used anywhere in the module, let's drop it.
This patch will help to hit this bug:
https://launchpad.net/bugs/1492636
Related-Bug: #1492636
Depends-On: I3ac207f744847b5742fc331d2c16d1dad475f9ea
Change-Id: I1e88361018fbbff42cae7e57f2e039fa45eaaeb1
25 lines
661 B
Puppet
25 lines
661 B
Puppet
#
|
|
# Class to execute "gnocchi-dbsync"
|
|
#
|
|
# [*user*]
|
|
# (optional) User to run dbsync command.
|
|
# Defaults to 'gnocchi'
|
|
#
|
|
class gnocchi::db::sync (
|
|
$user = 'gnocchi',
|
|
){
|
|
|
|
exec { 'gnocchi-db-sync':
|
|
command => 'gnocchi-upgrade --config-file /etc/gnocchi/gnocchi.conf',
|
|
path => '/usr/bin',
|
|
refreshonly => true,
|
|
user => $user,
|
|
logoutput => on_failure,
|
|
}
|
|
|
|
Package<| tag == 'gnocchi-package' |> ~> Exec['gnocchi-db-sync']
|
|
Exec['gnocchi-db-sync'] ~> Service<| tag == 'gnocchi-db-sync-service' |>
|
|
Gnocchi_config<||> ~> Exec['gnocchi-db-sync']
|
|
Gnocchi_config<| title == 'indexer/url' |> ~> Exec['gnocchi-db-sync']
|
|
}
|