[CentOS] Apache not liking directories outside of /var/www

Fri Jul 31 17:20:21 UTC 2009
jacob at aers.ca <jacob at aers.ca>

sounds like current default apache security
near the begining you of httpd.conf you will find 
<Directory />
    Options FollowSymLinks
    AllowOverride None

<Directory "/var/www/html">
    Options Indexes FollowSymLinks
    AllowOverride None
    Order allow,deny
    Allow from all

This effectively blocks you from sharing any directory (even aliased ones) unless the actual directory (no symlinks or aliases) is under /var/www. 
to add in exceptions put this under your alias statement.

Alias /test /home/test
<Directory /home/test>
        Order allow,deny
        Allow from all


From: centos-bounces at centos.org on behalf of Boris Epstein
Sent: Fri 7/31/2009 9:17 AM
To: centos at centos.org
Subject: [CentOS] Apache not liking directories outside of /var/www

Hi all,

It appears that on my nice little CentOS 5.3 machines Apache only
allows me to store content in directories which are under /var/www/

For instance, putting content in /var/www/test and defining the following alias:

Alias /test /var/www/test

then accessing it under http://hostname/test works great.

Not copy that same content to /home/test, change the alias to:

Alias /test /home/test

and you get Error 403.

Any idea why that would be?

Never had this sort of trouble anywhere, including under CentOS 5.0 and 5.1

Thanks in advance for any and all help.

CentOS mailing list
CentOS at centos.org

-------------- next part --------------
A non-text attachment was scrubbed...
Name: winmail.dat
Type: application/ms-tnef
Size: 5171 bytes
Desc: not available
URL: <http://lists.centos.org/pipermail/centos/attachments/20090731/99c4225d/attachment-0005.bin>