|
Home > Archive > Apache Server configuration support > August 2007 > getting user's public_html directories served up
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
getting user's public_html directories served up
|
|
| Peter Clinch 2007-08-30, 1:23 pm |
| I'm almost there, but not quite...
I'm using Apache2 as supplied with SuSE 10.2. I've enabled the daemon
and it works (I get the "It works!" page). Changing from the
as-supplied setup (which includes the userdir module), I went into
httpd.conf and added
<IfModule mod_userdir.c>
UserDir public_html
UserDir disabled root
</IfModule>
which brings the users' public_html into the frame, but I get a 403 if I
try and access them.
I've tried both adding executable permission to the user's home
directory and adding
<Directory /home/*/public_html>
Options All -Indexes
AllowOverride All
Order allow,deny
Allow from all
</Directory>
to the config file, but I'm still getting those 403s :-(
Any suggestions as to what's still borken?
Ta, Pete.
--
Peter Clinch Medical Physics IT Officer
Tel 44 1382 660111 ext. 33637 Univ. of Dundee, Ninewells Hospital
Fax 44 1382 640177 Dundee DD1 9SY Scotland UK
net p.j.clinch@dundee.ac.uk http://www.dundee.ac.uk/~pjclinch/
| |
| Davide Bianchi 2007-08-30, 1:23 pm |
| On 2007-08-30, Peter Clinch <p.j.clinch@dundee.ac.uk> wrote:
> which brings the users' public_html into the frame, but I get a 403 if I
> try and access them.
Check in the error_log, there should be a better error message.
Davide
--
Q: How many Microsoft support staff does it take to change a light bulb?
A: Four. One to ask "What is the registration number of the light bulb?", one
to ask "Have you tried rebooting it?", another to ask "Have you tried
reinstalling it?" and the last one to say "It must be your hardware because
the light bulb in our office works fine..."
| |
| Peter Clinch 2007-08-30, 1:23 pm |
| Davide Bianchi wrote:
> On 2007-08-30, Peter Clinch <p.j.clinch@dundee.ac.uk> wrote:
>
> Check in the error_log, there should be a better error message.
[error] [client 127.0.0.2] Directory index forbidden by Options
directive: /home/joetest/public_html/
I note that in the httpd.conf, higher up there's a fairly secure looking
default:
<Directory />
Options None
AllowOverride None
Order deny,allow
Deny from all
</Directory>
Is that over-riding my subsequent
<Directory /home/*/public_html>
Options All -Indexes
AllowOverride All
Order allow,deny
Allow from all
</Directory>
addition?
Thanks, Pete.
--
Peter Clinch Medical Physics IT Officer
Tel 44 1382 660111 ext. 33637 Univ. of Dundee, Ninewells Hospital
Fax 44 1382 640177 Dundee DD1 9SY Scotland UK
net p.j.clinch@dundee.ac.uk http://www.dundee.ac.uk/~pjclinch/
| |
| Davide Bianchi 2007-08-30, 1:23 pm |
| On 2007-08-30, Peter Clinch <p.j.clinch@dundee.ac.uk> wrote:
>
> [error] [client 127.0.0.2] Directory index forbidden by Options
> directive: /home/joetest/public_html/
So, he can reach the directory and hence is not a permission problem,
he knows to look for the public_html bit so the configuration is
(more or less) ok, the only problem is that there is no index.html
file in there so he can't show anything.
><Directory /home/*/public_html>
> Options All -Indexes
All but -Indexes means that the list of files won't be shown. If you
don't have an index.html file in the directory you get an error.
You either remove the -Indexes option or add an index.html file.
Davide
--
Linux - because software problems should not cost money.
-- Shlomi Fish
| |
| phantom 2007-08-30, 1:23 pm |
| "Peter Clinch" <p.j.clinch@dundee.ac.uk> wrote in message
news:5jo0aeFh2sjU1@mid.individual.net...
> Davide Bianchi wrote:
>
> [error] [client 127.0.0.2] Directory index forbidden by Options
> directive: /home/joetest/public_html/
>
> I note that in the httpd.conf, higher up there's a fairly secure looking
> default:
>
> <Directory />
> Options None
> AllowOverride None
> Order deny,allow
> Deny from all
> </Directory>
>
> Is that over-riding my subsequent
>
> <Directory /home/*/public_html>
> Options All -Indexes
> AllowOverride All
> Order allow,deny
> Allow from all
> </Directory>
>
> addition?
>
No, the first is the default which you are then overriding later.
As you are using "-Indexes" you will receive a 403 if the user doesn't have
an index.html (or similar)
This is what is meant by "Directory index forbidden by Options directive"
| |
| Peter Clinch 2007-08-30, 1:23 pm |
| Davide Bianchi wrote:
> All but -Indexes means that the list of files won't be shown. If you
> don't have an index.html file in the directory you get an error.
> You either remove the -Indexes option or add an index.html file.
Aha! Yes, it works fine now (and I /was/ missing something I should
have found while RTFM...)
many thanks for your (very fast!) input! :-)
cheers, Pete.
--
Peter Clinch Medical Physics IT Officer
Tel 44 1382 660111 ext. 33637 Univ. of Dundee, Ninewells Hospital
Fax 44 1382 640177 Dundee DD1 9SY Scotland UK
net p.j.clinch@dundee.ac.uk http://www.dundee.ac.uk/~pjclinch/
|
|
|
|
|