Apache 유저 디렉터리 설정 방법을 추가적으로 정리한다.
[root@localhost ~]# vi /etc/httpd/conf/httpd.conf
편집모드에서 다음 내용을 수정한다.
<IfModule mod_userdir.c>
#
# UserDir is disabled by default since it can confirm the presence
# of a username on the system (depending on home directory
# permissions).
#
#UserDir disabled
// #을 붙여 주석처리한다.
#
# To enable requests to /~user/ to serve the user's public_html
# directory, remove the "UserDir disabled" line above, and uncomment
# the following line instead:
#
UserDir public_html
// #을 없앤다.
</IfModule>
#
# Control access to UserDir directories. The following is an example
# for a site where these directories are restricted to read-only.
#
<Directory /home/*/public_html>
// </Directory> 까지 붙은 #을 없앤다.
AllowOverride FileInfo AuthConfig Limit
Options MultiViews Indexes SymLinksIfOwnerMatch IncludesNoExec
<Limit GET POST OPTIONS>
Order allow,deny
Allow from all
</Limit>
<LimitExcept GET POST OPTIONS>
Order deny,allow
Deny from all
</LimitExcept>
</Directory>
저장하고 빠져나온다.
[root@localhost ~]# service httpd restart
끝 !