Fedora 19
Sponsored Link

Enable Userdir2013/07/08

 
Enable userdir, users can build websites with this config.
[1] Configure httpd
[root@www ~]#
vi /etc/httpd/conf.d/userdir.conf
# line 17: make it comment

#
UserDir disabled
# line 24: uncomment

UserDir public_html
# line 31 - 35

<Directory "/home/*/public_html">
    AllowOverride
All
# change

    Options
None
# change

    Require method GET POST OPTIONS
</Directory>
[root@www ~]#
systemctl restart httpd.service

[2] Create a CGI test page in a user's home directory and access to it with web browser. It's OK if following page is shown.
[fedora@www ~]$
mkdir public_html

[fedora@www ~]$
chmod 711 /home/fedora

[fedora@www ~]$
chmod 755 /home/fedora/public_html

[fedora@www ~]$
vi ./public_html/index.html
<html>
<body>
<div style="width: 100%; font-size: 40px; font-weight: bold; text-align: center;">
UserDir Test Page
</div>
</body>
</html>
Matched Content