Merge "Let dib fix selinux policy for us"

This commit is contained in:
Jenkins 2016-04-22 13:30:04 +00:00 committed by Gerrit Code Review
commit efd502e981

View File

@ -33,16 +33,6 @@ mv /tmp/forwarding.conf /etc/unbound/
chown root:root /etc/unbound/forwarding.conf
chmod a+r /etc/unbound/forwarding.conf
# If we have selinux install, restore default SELinux contents when ever
# possible. Currently this only seems relevant for RHEL based DIBs.
SETFILES=$(which setfiles || true)
if [ -e /etc/selinux/targeted/contexts/files/file_contexts -a -x "${SETFILES}" ]; then
# Without fixing selinux file labels, sshd will run in the kernel_t domain
# instead of the sshd_t domain, making ssh connections fail with
# "Unable to get valid context for <user>" error message
setfiles /etc/selinux/targeted/contexts/files/file_contexts /etc/unbound
fi
# Overwrite /etc/resolv.conf at boot
dd of=/etc/rc.local <<EOF