Puppet Class: st2::rulesengine

Inherits:
st2
Defined in:
manifests/rulesengine.pp

Summary

Manages the st2rulesengine service (Orquesta)

Overview

Normally this class is instantiated by st2::profile::fullinstall. However, advanced users can instantiate this class directly to configure and manage just the st2rulesengine service on a single node. Parameters for this class mirror the parameters in the st2 config.

Examples:

Basic usage

include st2::rulesengine

Parameters:

  • rulesengine_num (Any) (defaults to: $st2::rulesengine_num)

    The number of rulesengines to have in an active active state

  • rulesengine_services (Any) (defaults to: $st2::params::rulesengine_services)

    Name of all the rulesengine services

See Also:



18
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
# File 'manifests/rulesengine.pp', line 18

class st2::rulesengine (
  $rulesengine_num      = $st2::rulesengine_num,
  $rulesengine_services = $st2::params::rulesengine_services,
) inherits st2 {

  $_logger_config = $st2::syslog ? {
    true    => 'syslog',
    default => 'logging',
  }

  ########################################
  ## Config
  ini_setting { 'rulesengine_logging':
    ensure  => present,
    path    => '/etc/st2/st2.conf',
    section => 'rulesengine',
    setting => 'logging',
    value   => "/etc/st2/${_logger_config}.rulesengine.conf",
    tag     => 'st2::config',
  }

  st2::service { 'st2rulesengine':
    service_name      => 'st2rulesengine',
    service_num       => $rulesengine_num,
    existing_services => $rulesengine_services,
  }
}