diff options
author | Ismaël Bouya <ismael.bouya@normalesup.org> | 2018-07-26 12:01:01 +0200 |
---|---|---|
committer | Ismaël Bouya <ismael.bouya@normalesup.org> | 2018-07-26 12:02:36 +0200 |
commit | 60fb787df260a2fb9cd87761d19eed6e78d0d797 (patch) | |
tree | cd608b20f8278f1a5fe5f861cde584bb3423132a /modules/profile | |
parent | ec722a207df43c5cb7f69ec91ae0e9d734414c4a (diff) | |
download | Puppet-60fb787df260a2fb9cd87761d19eed6e78d0d797.tar.gz Puppet-60fb787df260a2fb9cd87761d19eed6e78d0d797.tar.zst Puppet-60fb787df260a2fb9cd87761d19eed6e78d0d797.zip |
Fix freshness for monitoring
Diffstat (limited to 'modules/profile')
-rw-r--r-- | modules/profile/manifests/monitoring/local_service.pp | 18 | ||||
-rw-r--r-- | modules/profile/manifests/monitoring/params.pp | 7 |
2 files changed, 15 insertions, 10 deletions
diff --git a/modules/profile/manifests/monitoring/local_service.pp b/modules/profile/manifests/monitoring/local_service.pp index 4d38d69..cf8ef78 100644 --- a/modules/profile/manifests/monitoring/local_service.pp +++ b/modules/profile/manifests/monitoring/local_service.pp | |||
@@ -31,16 +31,14 @@ define profile::monitoring::local_service ( | |||
31 | 31 | ||
32 | [true, false].each |$services_for_master| { | 32 | [true, false].each |$services_for_master| { |
33 | if $services_for_master { | 33 | if $services_for_master { |
34 | $default_local = { | 34 | $default_local = merge( |
35 | mode => "0644", | 35 | $::profile::monitoring::params::service_local_for_master, |
36 | target => $::profile::monitoring::params::services_for_master, | 36 | { |
37 | check_interval => $::profile::monitoring::params::service_local["check_interval"], | 37 | mode => "0644", |
38 | retry_interval => $::profile::monitoring::params::service_local["retry_interval"], | 38 | target => $::profile::monitoring::params::services_for_master, |
39 | host_name => $::profile::monitoring::params::service_local["host_name"], | 39 | servicegroups => $service_group, |
40 | use => $::profile::monitoring::params::service_types["passive"], | 40 | notify => [], |
41 | servicegroups => $service_group, | 41 | }) |
42 | notify => [], | ||
43 | } | ||
44 | $t = "master - " | 42 | $t = "master - " |
45 | $services_key = $master | 43 | $services_key = $master |
46 | } else { | 44 | } else { |
diff --git a/modules/profile/manifests/monitoring/params.pp b/modules/profile/manifests/monitoring/params.pp index 27f895e..285393c 100644 --- a/modules/profile/manifests/monitoring/params.pp +++ b/modules/profile/manifests/monitoring/params.pp | |||
@@ -39,4 +39,11 @@ class profile::monitoring::params { | |||
39 | retry_interval => "1", | 39 | retry_interval => "1", |
40 | }) | 40 | }) |
41 | 41 | ||
42 | $service_local_for_master = { | ||
43 | host_name => $service_local["host_name"], | ||
44 | check_interval => $service_local["check_interval"], | ||
45 | retry_interval => $service_local["retry_interval"], | ||
46 | check_freshness => Integer(Integer($service_local["check_interval"]) * 1.5), | ||
47 | use => $service_types["passive"], | ||
48 | } | ||
42 | } | 49 | } |