TCLUG Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [TCLUG:5849] virtual web hosts and public_html

I think JellyD has the virtual hosts described, I'll try the "each user will
have their own account". The version of apache that I use has an srm.conf
which includes the following:

# UserDir: The name of the directory which is appended onto a user's home
# directory if a ~user request is received.

UserDir www

I believe the latest version of Apache has consolidated the use of srm.conf,
access.conf and httpd.conf into one file httpd.conf. This scenario requires
each user to have their own shell account /home/torvalds/www and any
subsequent directories under www that are needed possibly including cgi-bin.

At this point it's all about file permissions. In order for apache to parse
through directories they need to be executable by "other". So chmod 755
/home/username produces:
drwxr-xr-x   9 rtp      rtp          1024 May  4 17:08 rtp

Files within /home/username/www/ can have permissions like the following:
-rw-r--r--   1 mi-r     mi-r          288 Apr  1 05:28 frame-1.jpg

If I understand apache's httpd.conf file then <virtualhosts> entries can
include every apache tag in the book. Allowing for a highly customizable
<virtualhost>. On the other hand, if every <virtualhost> will serve "www"
user webs then you could put the above UserDir tag within the global section
of the httpd.conf file thus eliminating the need to enter it within each
<virtualhost> and potentially saving some redundancy.

Anyway, I hope some of that is accurate and clear enough to make sense.

ron parker

As a side note: I think I know just enough to really screw things up. Several
days back, I decided to rebuild my server. I backed up my main web account
and neglected to do the same with five user webs "~/username". Three of which
exist elsewhere on my lan but the remaining two are unrecoverable. The web
gets deeper. I had everything backed up to tape but a faulty power supply
caused the server to crash while the only existing backup tape was in the
drive. After the crash I am unable to recover anything from that tape. I've
since dusted off my case of backup tapes, all of which are new and unopened.

Tim Wilson wrote:

> Hey everyone,
> I think I mentioned at the last TCLUG meeting that I had convinced our
> SysAdmin to use Linux/Apache for our district's web server. We've been
> meeting a little to plan it. Just a couple days ago I helped him install
> RH6.0 on an old Pentium box to test it out using some virtual hosts.
> We're going to create a different virtual host for each school so that
> visitors can point their browsers to or
> (for Mendota Elem. School). We will select a
> person who will be the official web master for each building and will give
> them an account on the web server. Additionally, we'd like to give
> individual teachers space for classroom web pages on their school's
> "virtual" web server.
> So, let's say that Joe Smith is a 5th grade teacher at Mendota and Susie
> Jones teaches at Sibley. Each person would have their own account on the
> server and would put their personal web pages in a 'public_html' folder in
> their home directory so that Apache could serve it up. How do we tell
> Apache that is one page and
> is the other? In other words, how will
> Apache properly associate a particular user's public_html folder with a
> particular virtual host?
> BTW, our SysAdmin was very impressed when we installed mars_nwe on the
> server to emulate a NetWare 3.11 server in about 30 min. Our idea is to
> allow users to mount their home directory on the Linux server via their
> regular NetWare login. Novice computer users should be able to simply drag
> and drop their web pages to a network folder and have them available. He
> was very impressed with how easy it was to set up. He's must be used to
> working with commercial software. :-)
> Later,
> Tim
> --
> Timothy D. Wilson                       "A little song, a little dance,
> University of MN, chem. dept.           a little seltzer down your
>                     pants."   -Chuckles the Clown
> Phone: (612) 625-9828                       as eulogized by Ted Baxter
> ---------------------------------------------------------------------
> To unsubscribe, e-mail:
> For additional commands, e-mail:
> Try our website: