Fixed SELinux context from apache logrotate script in Fedora.
This commit is contained in:
parent
f9dc49e9ae
commit
f7298b5671
1 changed files with 10 additions and 3 deletions
|
@ -81,9 +81,16 @@ class apache::common {
|
||||||
group => "root",
|
group => "root",
|
||||||
seltype => "httpd_rotatelogs_exec_t",
|
seltype => "httpd_rotatelogs_exec_t",
|
||||||
}
|
}
|
||||||
selinux::manage_fcontext { "/usr/local/sbin/www-logrotate.sh":
|
if $::operatingsystem == "Fedora" and $::operatingsystemrelease > 17 {
|
||||||
type => "httpd_rotatelogs_exec_t",
|
selinux::manage_fcontext { "/usr/sbin/www-logrotate.sh":
|
||||||
before => File["/usr/local/sbin/www-logrotate.sh"],
|
type => "httpd_rotatelogs_exec_t",
|
||||||
|
before => File["/usr/local/sbin/www-logrotate.sh"],
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
selinux::manage_fcontext { "/usr/local/sbin/www-logrotate.sh":
|
||||||
|
type => "httpd_rotatelogs_exec_t",
|
||||||
|
before => File["/usr/local/sbin/www-logrotate.sh"],
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
cron { "www-logrotate":
|
cron { "www-logrotate":
|
||||||
|
|
Loading…
Add table
Reference in a new issue