Restore proper SELinux context for runtime created /var/run/nut directory

This commit is contained in:
Laurent Bigonville 2012-10-09 23:38:43 +02:00
parent 5b99c93354
commit c79bcd71af
5 changed files with 8 additions and 3 deletions

View file

@ -52,7 +52,8 @@ fi
check_var_directory() {
[ ! -d ${pid_dir} ] && mkdir -p ${pid_dir} \
&& chown root:nut ${pid_dir} \
&& chmod 770 ${pid_dir}
&& chmod 770 ${pid_dir} \
&& [ -x /sbin/restorecon ] && /sbin/restorecon ${pid_dir}
}
# check if the right components are running