Puppet Class: icinga2::globals

Defined in:
manifests/globals.pp

Overview

[*service_reload*] How to do a reload of the Icinga process.

[*constants*] Set default constants.

=== Examples

This class is private and should not be called by others than this module.

Parameters:

  • package_name (String)
  • service_name (String)
  • ido_mysql_schema (String)
  • ido_pgsql_schema (String)
  • icinga2_bin (Stdlib::Absolutepath)
  • conf_dir (Stdlib::Absolutepath)
  • lib_dir (Stdlib::Absolutepath)
  • log_dir (Stdlib::Absolutepath)
  • run_dir (Stdlib::Absolutepath)
  • spool_dir (Stdlib::Absolutepath)
  • cache_dir (Stdlib::Absolutepath)
  • cert_dir (Stdlib::Absolutepath)
  • ca_dir (Stdlib::Absolutepath)
  • reserved (Array[String])
  • user (Optional[String]) (defaults to: undef)
  • group (Optional[String]) (defaults to: undef)
  • ido_mysql_package_name (Optional[String]) (defaults to: undef)
  • ido_pgsql_package_name (Optional[String]) (defaults to: undef)
  • service_reload (Optional[String]) (defaults to: undef)


82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
# File 'manifests/globals.pp', line 82

class icinga2::globals(
  String                 $package_name,
  String                 $service_name,
  String                 $ido_mysql_schema,
  String                 $ido_pgsql_schema,
  Stdlib::Absolutepath   $icinga2_bin,
  Stdlib::Absolutepath   $conf_dir,
  Stdlib::Absolutepath   $lib_dir,
  Stdlib::Absolutepath   $log_dir,
  Stdlib::Absolutepath   $run_dir,
  Stdlib::Absolutepath   $spool_dir,
  Stdlib::Absolutepath   $cache_dir,
  Stdlib::Absolutepath   $cert_dir,
  Stdlib::Absolutepath   $ca_dir,
  Array[String]          $reserved,
  Optional[String]       $user                   = undef,
  Optional[String]       $group                  = undef,
  Optional[String]       $ido_mysql_package_name = undef,
  Optional[String]       $ido_pgsql_package_name = undef,
  Optional[String]       $service_reload         = undef,
) {

  assert_private()

  if ( versioncmp($::puppetversion, '6' ) >= 0 and versioncmp(load_module_metadata('stdlib')['version'], '5.1.0') < 0 ) {
    fail('You be affected by this bug: https://github.com/Icinga/puppet-icinga2/issues/505 so you should update your stdlib to version 5.1 or higher')
  }

  $constants =  lookup('icinga2::globals::constants', Hash, 'deep', {})

}