File README.SELinux of Package owncloud
NOTE: IF YOU INSTALLED FROM THE OFFICIAL OWNCLOUD RPM, YOU DO NOT NEED TO
FOLLOW THE INSTRUCTIONS BELOW! THEY HAVE ALREADY BEEN DONE FOR YOU!
If you are running Fedora 16 with SELinux enabled, you need to relabel the
ownCloud installation directory to allow the webserver to store files there.
To do that, execute the following commands as user root AFTER you installed
ownCloud:
# semanage fcontext -a -t httpd_sys_rw_content_t '/var/www/html/owncloud/data'
# restorecon '/var/www/html/owncloud/data'
# semanage fcontext -a -t httpd_sys_rw_content_t '/var/www/html/owncloud/config'
# restorecon '/var/www/html/owncloud/config'
To remove the ownCloud directory label execute the following commands as
user root AFTER you uninstalled ownCloud:
# semanage fcontext -d -t httpd_sys_rw_content_t '/var/www/html/owncloud/data'
# restorecon '/var/www/html/owncloud/data'
# semanage fcontext -d -t httpd_sys_rw_content_t '/var/www/html/owncloud/config'
# restorecon '/var/www/html/owncloud/config'
Note: all of the above applies only to the default policies. If you modified
them, please give the webserver write-access to the directories
/var/www/html/owncloud/data and /var/www/html/owncloud/config
Note: for non-Fedora / Redhat systems running SELinux the policy might be
called differently.
Enjoy you own Cloud!