From 85c3fba95368a59d923583ea4f84155c7e12ae3d Mon Sep 17 00:00:00 2001 From: Ossi Salmi Date: Thu, 19 Jul 2012 12:30:08 +0300 Subject: [PATCH] Added check for selinux state in selinux::boolean --- puppet/manifests/init.pp | 2 +- selinux/manifests/init.pp | 8 +++++--- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/puppet/manifests/init.pp b/puppet/manifests/init.pp index 9ca59b3..4437b82 100644 --- a/puppet/manifests/init.pp +++ b/puppet/manifests/init.pp @@ -271,7 +271,7 @@ class puppet::server::common inherits puppet::client { } "mysql": { require ruby::mysql - if $::selinux == "true" and $::operatingsystem == "CentOS" and $::operatingsystemrelease !~ /^[1-5]\..*/ { + if $::operatingsystem == "CentOS" and $::operatingsystemrelease !~ /^[1-5]\..*/ { selinux::boolean { "puppetmaster_use_db": value => "on", } diff --git a/selinux/manifests/init.pp b/selinux/manifests/init.pp index 81f5bce..6671162 100644 --- a/selinux/manifests/init.pp +++ b/selinux/manifests/init.pp @@ -109,9 +109,11 @@ class selinux::tools { # define selinux::boolean($value) { - selboolean { $name: - value => $value, - persistent => true, + if $::selinux == "true" { + selboolean { $name: + value => $value, + persistent => true, + } } }