You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Erik Sabowski <ai...@hotmail.com> on 2000/10/04 16:47:13 UTC

context for ~user directories?

is there a context path that can be put in the server.xml file so that each 
of the users on our network can have their own app in their public_html 
directory? basically i'm just wondering if there is some way to do it 
without having to add a context path for each individual user...

running tomcat 1.3 with apache 1.3.12

thanks

erik
_________________________________________________________________________
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.

Share information about yourself, create your own public profile at 
http://profiles.msn.com.


Re: context for ~user directories?

Posted by "Craig R. McClanahan" <Cr...@eng.sun.com>.
James Cribb wrote:

> Erik Sabowski wrote:
> >
> > is there a context path that can be put in the server.xml file so that each
> > of the users on our network can have their own app in their public_html
> > directory? basically i'm just wondering if there is some way to do it
> > without having to add a context path for each individual user...
>
> Lots of us have been asking that question.  I'll now go out on a limb
> and say, no, it can't be done, you have to manually edit server.xml each
> time a new user is added to the system.  I'd love to be proved wrong.
> (I'm talking about Tomcat 3.1, I don't know about the beta versions.)

Tomcat 4.0 has such a gadget -- it can scan all the user home directories listed
in /etc/passwd (options exist to do other things as well) and add webapps for
those that have a "public_html" directory that looks like a webapp.  This is done
by adding a listener inside the <Host> declaration in
$CATALINA_HOME/conf/server.xml:

    <Host name="localhost" ...>
        <Listener className="org.apache.catalina.startup.UserConfig"/>
        ...
    </Host>

I don't believe Tomcat 3.1 or 3.2 has such a tool -- although it would be
possible to write one in either environment usting the context interceptor
architecture.

Craig McClanahan

====================
See you at ApacheCon Europe <http://www.apachecon.com>!
Session VS01 (23-Oct 13h00-17h00):  Sun Technical Briefing
Session T06  (24-Oct 14h00-15h00):  Migrating Apache JServ
                                    Applications to Tomcat



Re: context for ~user directories?

Posted by James Cribb <ja...@zip.com.au>.
Erik Sabowski wrote:
> 
> is there a context path that can be put in the server.xml file so that each
> of the users on our network can have their own app in their public_html
> directory? basically i'm just wondering if there is some way to do it
> without having to add a context path for each individual user...

Lots of us have been asking that question.  I'll now go out on a limb
and say, no, it can't be done, you have to manually edit server.xml each
time a new user is added to the system.  I'd love to be proved wrong. 
(I'm talking about Tomcat 3.1, I don't know about the beta versions.)