SELinux restricting access to a folder which in turn prevents my apache config access the document root.
- I have SELinux turned on.
=== No Problem with the following: ===
/etc/httpd/conf/httpd.conf:
<VirtualHost *:80>
ServerAdmin
root@www.clare.com
DocumentRoot /var/www/html/clare.dev
ServerName
www.clare.com
ErrorLog logs/www.clare.com-error_log
CustomLog logs/www.clare.com-access_log common
</VirtualHost>
I can access the site.
=== Problem arises when: ===
I change the folder to a higher level:
DocumentRoot to /claresite
[error] [client 127.0.0.1] client denied by server configuration: /claresite/
Here are my return results:
root@linux1 logs/ # ls -Z /claresite/
-rw-r--r-- root root root
bject_r:httpd_sys_content_t index.html
root@linux1 logs/ # ls -Z /var/www/html/clare.dev/
-rw-r--r-- root root root
bject_r:httpd_sys_content_t index.html
I'm new to SELinux and I can't find out why this is happening? Can anyone share some ideas on why this is occurring?
TIA