Puppet Class: ec2api::db::sync

Inherits:
ec2api::params
Defined in:
manifests/db/sync.pp

Overview

Class: ec2api::db::sync

Class to execute “ec2api-manage db_sync”

Parameters

system_user

(Optional) Run db_sync from this system user account. Default to $::ec2api::params::user

system_group

(Optional) Run db_sync by this system group. Default to $::ec2api::params::group

db_sync_timeout

(Optional) Timeout for the execution of the db_sync Defaults to 300

Parameters:

  • system_user (Any) (defaults to: $::ec2api::params::user)
  • system_group (Any) (defaults to: $::ec2api::params::group)
  • db_sync_timeout (Any) (defaults to: 300)


19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
# File 'manifests/db/sync.pp', line 19

class ec2api::db::sync (
  $system_user     = $::ec2api::params::user,
  $system_group    = $::ec2api::params::group,
  $db_sync_timeout = 300,
) inherits ec2api::params {

  include ec2api::deps

  exec { 'ec2api_db_sync' :
    command     => 'ec2-api-manage db_sync',
    path        => '/usr/bin',
    user        => $system_user,
    group       => $system_group,
    refreshonly => true,
    try_sleep   => 5,
    tries       => 10,
    timeout     => $db_sync_timeout,
    logoutput   => on_failure,
    subscribe   => [
      Anchor['ec2api::install::end'],
      Anchor['ec2api::config::end'],
      Anchor['ec2api::dbsync::begin']
    ],
    notify      => Anchor['ec2api::dbsync::end'],
    tag         => 'openstack-db',
  }

}