summaryrefslogtreecommitdiff
path: root/manifests/debian.pp
diff options
context:
space:
mode:
authorvarac <varacanero@zeromail.org>2016-03-10 17:19:52 +0100
committervarac <varacanero@zeromail.org>2016-03-10 17:22:26 +0100
commitc4f9160f135243f305669e1a731812dd6c3573de (patch)
treefcffea399a7d33b8fe2d5cfbe64f3dde18a1258b /manifests/debian.pp
parentbad75052820f221df575a1942417712e35ab1af7 (diff)
Improve relationship of nagios resources
Diffstat (limited to 'manifests/debian.pp')
-rw-r--r--manifests/debian.pp9
1 files changed, 7 insertions, 2 deletions
diff --git a/manifests/debian.pp b/manifests/debian.pp
index 9b1f7e7..39af973 100644
--- a/manifests/debian.pp
+++ b/manifests/debian.pp
@@ -21,11 +21,13 @@ class nagios::debian inherits nagios::base {
notify => Service['nagios'],
owner => root,
group => root,
- mode => '0644';
+ mode => '0644',
+ require => Package['nagios'];
"${nagios::defaults::vars::int_cfgdir}/stylesheets":
ensure => directory,
purge => false,
- recurse => true;
+ recurse => true,
+ require => Package['nagios'];
}
if $nagios::allow_external_cmd {
@@ -34,16 +36,19 @@ class nagios::debian inherits nagios::base {
unless => 'dpkg-statoverride --list nagios www-data 2710 /var/lib/nagios3/rw && dpkg-statoverride --list nagios nagios 751 /var/lib/nagios3',
logoutput => false,
notify => Service['nagios'],
+ require => Package['nagios'],
}
exec { 'nagios_external_cmd_perms_1':
command => 'chmod 0751 /var/lib/nagios3 && chown nagios:nagios /var/lib/nagios3',
unless => 'test "`stat -c "%a %U %G" /var/lib/nagios3`" = "751 nagios nagios"',
notify => Service['nagios'],
+ require => Package['nagios'],
}
exec { 'nagios_external_cmd_perms_2':
command => 'chmod 2751 /var/lib/nagios3/rw && chown nagios:www-data /var/lib/nagios3/rw',
unless => 'test "`stat -c "%a %U %G" /var/lib/nagios3/rw`" = "2751 nagios www-data"',
notify => Service['nagios'],
+ require => Package['nagios'],
}
}
}