To enable per-user web directories on SELinux enabled FC3+, edit /etc/httpd/conf/httpd.conf:
- Comment out the line UserDir disable
- Add UserDir public_html.
- Save the file and run service httpd reload
Each user who needs web directories must do the following:
- Create ~/public_html, and populate it. 
- Change perms with chmod
- Change the security context of the folder recursively:
 chcon -R -t httpd_user_content_t ~/public_html/
 
At this point, it should work. If it does not, check to see that the Boolean that enables user home directories is enabled:
- Run system-config-securitylevel
- Under the SELinux tab within the Modify SELinux Policy area: 
enable Allow HTTPD to read home directories.
- Alternatively, execute 
 setsebool httpd_enable_homedirs true
No comments:
Post a Comment