diff --git a/ldap/manifests/init.pp b/ldap/manifests/init.pp index 81a6e4f..51a23b7 100644 --- a/ldap/manifests/init.pp +++ b/ldap/manifests/init.pp @@ -530,16 +530,14 @@ class ldap::server { } } - if $::selinux == "true" { - selinux::manage_fcontext { "/srv/ldap(/.*)?": + selinux::manage_fcontext { "/srv/ldap(/.*)?": + type => "slapd_db_t", + before => File["/srv/ldap"], + } + if $ldap_datadir { + selinux::manage_fcontext { "${ldap_datadir}(/.*)?": type => "slapd_db_t", - before => File["/srv/ldap"], - } - if $ldap_datadir { - selinux::manage_fcontext { "${ldap_datadir}(/.*)?": - type => "slapd_db_t", - before => File[$ldap_datadir], - } + before => File[$ldap_datadir], } }