puppet-glance/manifests/db/sync.pp
Nate Potter 166af71b1f Correct db sync for backwards compatibility
In the previous patch https://review.openstack.org/#/c/241003/4
the default value for the config file when running glance-manage
db sync was changed. This patch restores the old default value
for backwards compatibility.

Change-Id: I1c17461bf7f4922ece41673f3f726ec00b0cd4c7
2015-11-19 16:31:13 +00:00

34 lines
1000 B
Puppet

#
# Class to execute glance dbsync
#
# == Parameters
#
# [*extra_params*]
# (optional) String of extra command line parameters to append
# to the glance-manage db sync command. These will be inserted
# in the command line between 'glance-manage' and 'db sync'.
# Defaults to '--config-file /etc/glance/glance-registry.conf'
#
class glance::db::sync(
$extra_params = '--config-file /etc/glance/glance-registry.conf',
) {
include ::glance::params
Package<| tag == 'glance-package' |> ~> Exec['glance-manage db_sync']
Exec['glance-manage db_sync'] ~> Service<| tag == 'glance-service' |>
Glance_registry_config<||> ~> Exec['glance-manage db_sync']
Glance_api_config<||> ~> Exec['glance-manage db_sync']
Glance_cache_config<||> ~> Exec['glance-manage db_sync']
exec { 'glance-manage db_sync':
command => "glance-manage ${extra_params} db_sync",
path => '/usr/bin',
user => 'glance',
refreshonly => true,
logoutput => on_failure,
}
}