summaryrefslogtreecommitdiff
path: root/manifests/plugin.pp
diff options
context:
space:
mode:
authormh <mh@immerda.ch>2012-02-15 18:17:14 +0100
committermh <mh@immerda.ch>2012-02-15 18:17:14 +0100
commitd459255da087bda68627dc5c228056b6ebf7036b (patch)
tree9235ff7627fafadc9515ecbffe42ff038adfcc8c /manifests/plugin.pp
parentd8de9540534a3801c87278435934da3c88a69e4b (diff)
manage selinux if enabled of plugins we manage
Diffstat (limited to 'manifests/plugin.pp')
-rw-r--r--manifests/plugin.pp8
1 files changed, 6 insertions, 2 deletions
diff --git a/manifests/plugin.pp b/manifests/plugin.pp
index 69b7322..b76a5da 100644
--- a/manifests/plugin.pp
+++ b/manifests/plugin.pp
@@ -21,7 +21,7 @@ define munin::plugin (
file { $plugin: ensure => absent, }
}
default: {
- case $kernel {
+ case $::kernel {
openbsd: { $basic_require = File['/var/run/munin'] }
default: { $basic_require = Package['munin-node'] }
}
@@ -35,7 +35,11 @@ define munin::plugin (
require => $real_require,
notify => Service['munin-node'];
}
-
+ if $::selinux == 'true' {
+ File[$plugin]{
+ setype => 'munin_services_plugin_exec_t',
+ }
+ }
}
}
case $config {