[SLUG] Re: configuring apache rendering file list in a directory.

From: Ken Billings (lists@coffeehouseltd.com)
Date: Wed May 15 2002 - 15:04:01 EDT


Patrick (at work) writes:

> I was getting a 404
> The error log:
> File does not exist: /usr/local/httpd/htdocs/home/shared/common
>
> I created a symbolic link in
> /usr/local/httpd/htdocs called
> common
>
> Now I am getting a 403 - forbidden
> Symbolic link not allowed: /usr/local/httpd/htdocs/common

   Options FollowSymLinks

> I am trying to create (in M$ lingo) a virtual directory
> under
> /usr/local/httpd/htdocs that points to
> /usr/local/httpd/htdocs/home/shared/common
> so that
> a browser pointed to http://www.myserver.com/common
> will list the files in
> /usr/local/httpd/htdocs/common

Put this directive in the config file:

   Alias /common /usr/local/httpd/htdocs/common

and this one also if you want a trailing slash to work (it's picky):

   Alias /common/ /usr/local/httpd/htdocs/common/

This is in addition to the statement from Matt Miller (modified):

   <Directory /usr/local/httpd/htdocs/common>
      Options Indexes
      order allow,deny
      allow from all
   </Directory>

If you don't want the access rights to be different than your main site
config, you can leave out the order and allow directives.
You can do something like this either way - by using a symlink, or the
prefered method of using the Alias directive.

> When any changes are made to I have to stop and restart Apache? Or are the
> conf files parsed with each access?

Restart is necessary, or send the main process a SIGHUP signal.

 -Ken



This archive was generated by hypermail 2.1.3 : Fri Aug 01 2014 - 18:37:00 EDT