LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 02-15-2004, 02:04 AM   #1
drkfir5
Member
 
Registered: Jan 2004
Distribution: SuSE 9.0
Posts: 41

Rep: Reputation: 15
apache config.


Howdy,
I'm trying to configure my apache webserver.
Does anyone know what I need to do to allow the httpd to view users directories?
(i.e. the contence of "http://192.168.0.38/~drkfir5/bits-n-bobs/" or in reality "/home/drkfir5/public_html/bits-n-bobs/")

Along the same lines, how about non-user directories? (i.e. "/scratch/"?)

Any help would be appriciated.

P.S.
I RTFM but I'm not experianced at apache to understand half of it.
 
Old 02-15-2004, 06:45 AM   #2
swobodin
LQ Newbie
 
Registered: Feb 2004
Distribution: Fedora Core 3 , Knoppix 3.7 re-hackked, Kanotix, Ubuntu, Debian
Posts: 6

Rep: Reputation: 0
Hello, this is my first post at this forum, and I'm not an expert in Linux yet, but I hope I can help.
change group the home user directory to Apache (chgrp -Rv apache /home/user) and add execute to the public_html (chmod -v +x /home/user/public_html).
So did I, it works! :-)
 
Old 02-15-2004, 07:03 AM   #3
hw-tph
Senior Member
 
Registered: Sep 2003
Location: Sweden
Distribution: Debian
Posts: 3,032

Rep: Reputation: 58
You also need to make sure Apache is aware of the user's HTML directories:
Code:
<IfModule mod_userdir.c>
    UserDir public_html
</IfModule>
...and
Code:
<Directory /home/*/public_html>
    AllowOverride All
    Options MultiViews -Indexes Includes FollowSymLinks
    Order allow,deny
    Allow from all
</Directory>
Want personal cgi directories as well?
Code:
<Directory /home/*/public_html/cgi-bin>
     Options +ExecCGI -Includes -Indexes
     SetHandler cgi-script
</Directory>
Håkan
 
Old 02-15-2004, 05:19 PM   #4
drphear
LQ Newbie
 
Registered: Feb 2004
Distribution: SELinux
Posts: 2

Rep: Reputation: 0
Also make sure that the files themselves are world readable.
 
Old 02-20-2004, 12:04 AM   #5
drkfir5
Member
 
Registered: Jan 2004
Distribution: SuSE 9.0
Posts: 41

Original Poster
Rep: Reputation: 15
swobodin, couldn't I just "chmod 777 /home/drkfir5" instead of changing the ownership of the directory? Because if I change ownership then I won't be able to write to the sector (unless it is changed to 777).

hw-tph, is there anywhere in particular I need to place the above code?
 
Old 02-20-2004, 07:25 AM   #6
hw-tph
Senior Member
 
Registered: Sep 2003
Location: Sweden
Distribution: Debian
Posts: 3,032

Rep: Reputation: 58
I like having a group to which I can add users to give them write access to the sitewide HTML directories (as opposed to their ~/public_html dirs). That way it's pretty easy to control who can do what.


Håkan
 
Old 02-27-2004, 07:57 PM   #7
bmcneil2k
LQ Newbie
 
Registered: Feb 2004
Posts: 16

Rep: Reputation: 0
Hey hw-tph

How do you create such a group, that can be able to write to assigned directories. for HTML file ect..
 
Old 03-01-2004, 01:16 AM   #8
drkfir5
Member
 
Registered: Jan 2004
Distribution: SuSE 9.0
Posts: 41

Original Poster
Rep: Reputation: 15
try vigrp and add the group, making sure to use a diffrent group number.
If you did 'man -k group' I'm sure it would give you a help page on how to do it.
 
Old 03-01-2004, 03:51 AM   #9
andrewlkho
Member
 
Registered: Jul 2003
Location: London
Posts: 548

Rep: Reputation: 31
For the apache config section, it should already be written in your httpd.conf file, just commented out. Do a quick search for "public_html", and you'll find it.
 
Old 10-25-2004, 02:05 AM   #10
drkfir5
Member
 
Registered: Jan 2004
Distribution: SuSE 9.0
Posts: 41

Original Poster
Rep: Reputation: 15
OK. It's time to revist this problem. Only different.
How can I set it up so that people can view the contence of my home directory?

Nvm. I figured it out.

Last edited by drkfir5; 10-27-2004 at 10:46 PM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
apache config doralsoral Linux - Software 1 11-04-2005 09:01 PM
apache config xpace Linux - Networking 22 08-26-2005 03:36 AM
Apache Config riluve Linux - Software 1 02-14-2005 02:42 PM
Apache config silmaril8n Linux - Newbie 8 11-11-2004 04:02 PM
Where is the config file for apache linuxmandrake Linux - Software 2 09-15-2004 05:35 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 02:18 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration