Well, you could try it and see.  Here is what is generated for me (attached)...

Jake

At 04:06 PM 3/20/2003 +0100, you wrote:
OK, thanks

But it generates <Virutalhost> directives and inside, there's only
JkMount's, no <Directory>, no Alias, right ?

What I really need (and I'm pretty sure I'm not the only one) is
something like this (for each of my contexts) :

> >#
> ># The following line makes apache aware of the location of the /examples
> >context
> >#
> >Alias /examples /var/tomcat4/webapps/examples
> ><Directory "/var/tomcat4/webapps/examples">
> >     Options Indexes FollowSymLinks
> ></Directory>
> >JkMount /examples/servlet/* ajp13
> >JkMount /examples/*.jsp ajp13
> ><Location "/examples/WEB-INF/">
> >     AllowOverride None
> >     deny from all
> ></Location>




On Thu, 2003-03-20 at 15:56, Jacob Kjome wrote:
>
> Close.  One inside the <Server> tag and one inside each <Host> tag that you
> want autogenerated.
>
> Here's mine...
>
> <Server ....>
> <Listener className="org.apache.ajp.tomcat4.config.ApacheConfig"
>              modJk="mod_jk.dll"
>              jkDebug="info" />
> ...
> ...
> ...
> <Host ...>
> <Listener className="org.apache.ajp.tomcat4.config.ApacheConfig"
>              append="true"
>              forwardAll="false" />
> ...
> ...
> ...
> </Host>
> ...
> ...
> ...
> </Server>
>
> Jake
>
> At 02:09 PM 3/20/2003 +0100, you wrote:
> >Well, thanks, but I've already read this. It is not really explaining
> >WHERE are supposed to be those "Listeners" that turn tomcat ApacheConfig
> >on.
> >
> >When you read the doc, it seems that you're supposed to put one listener
> >inside the <Server> tag and another one inside each <Context> tag
> >(remember I do not want to use Virtualhosting). It's not clear whether
> >you're supposed to use append="true" or not. In any cases, it does not
> >generate what I want (and there also seems to be some bugs in here :
> >restarting tomcat twice does not give the same mod_jk.conf). I've also
> >tried to put them in many places whithout success.
> >
> >However, I recently found a mod_jk.conf shipped with a RedHat RPM and it
> >seems to have been auto-generated as it contains the following lines :
> >
> >#
> ># The following line makes apache aware of the location of the /examples
> >context
> >#
> >Alias /examples /var/tomcat4/webapps/examples
> ><Directory "/var/tomcat4/webapps/examples">
> >     Options Indexes FollowSymLinks
> ></Directory>
> >JkMount /examples/servlet/* ajp13
> >JkMount /examples/*.jsp ajp13
> ><Location "/examples/WEB-INF/">
> >     AllowOverride None
> >     deny from all
> ></Location>
> >
> >
> >This group of directives is exactly what I need but I don't know how to
> >tell tomcat to generate them automatically. I'm almost forced to  make a
> >perl script to do something like "For each context you're managing,
> >generate an Alias, a Directory and a JkMount for Apache" (using perl to
> >manage a java application server... a bit strange isn't it ? :-)
> >
> >
> >On Thu, 2003-03-20 at 10:04, Bill Barker wrote:
> > > If it wasn't deprecated, I'd probably go back and add a 3.3-style all-in
> > > directive to the 4.x auto-config.
> > >
> > > In the mean-time go back and read
> > >
> > http://jakarta.apache.org/tomcat/tomcat-4.1-doc/config/jk.html#Using%20Apach
> > > eConfig.
> > >
> > > "Vincent Panel" <[EMAIL PROTECTED]> wrote in message
> > > news:[EMAIL PROTECTED]...
> > >
> > >
> > >
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > > For additional commands, e-mail: [EMAIL PROTECTED]
> > >
> >
> >
> >

########## Auto generated on Thu Mar 20 09:42:45 CST 2003##########

<IfModule !mod_jk.c>
  LoadModule jk_module C:/Java/Apache/Jakarta/tomcat-4.1.19/mod_jk.dll
</IfModule>

JkWorkersFile "C:/Java/Apache/Jakarta/tomcat-4.1.19/conf/jk/workers.properties"
JkLogFile "C:/Java/Apache/Jakarta/tomcat-4.1.19/logs/mod_jk.log"

JkLogLevel info



<VirtualHost localhost>
    ServerName localhost

    #################### localhost:/admin ####################

    # Static files 
    Alias /admin "C:/Java/Apache/Jakarta/tomcat-4.1.19/webapps/../server/webapps/admin"

    <Directory "C:/Java/Apache/Jakarta/tomcat-4.1.19/webapps/../server/webapps/admin">
        Options Indexes FollowSymLinks
        DirectoryIndex index.html index.htm index.jsp 
    </Directory>


    # Deny direct access to WEB-INF and META-INF
    #
    <Location "/admin/WEB-INF/*">
        AllowOverride None
        deny from all
    </Location>

    <Location "/admin/META-INF/*">
        AllowOverride None
        deny from all
    </Location>
    #
    # Use Directory too. On Windows, Location doesn't work unless case matches
    #
    <Directory 
"C:/Java/Apache/Jakarta/tomcat-4.1.19/webapps/../server/webapps/admin/WEB-INF/">
        AllowOverride None
        deny from all
    </Directory>

    <Directory 
"C:/Java/Apache/Jakarta/tomcat-4.1.19/webapps/../server/webapps/admin/META-INF/">
        AllowOverride None
        deny from all
    </Directory>

    JkMount /admin/j_security_check  ajp13
    JkMount /admin/*.do  ajp13
    JkMount /admin/*.jsp  ajp13

    #################### localhost:/gateway ####################

    # Static files 
    Alias /gateway "C:/Java/Apache/Jakarta/tomcat-4.1.19/webapps/gateway"

    <Directory "C:/Java/Apache/Jakarta/tomcat-4.1.19/webapps/gateway">
        Options Indexes FollowSymLinks
        DirectoryIndex index.html index.htm index.jsp 
    </Directory>


    # Deny direct access to WEB-INF and META-INF
    #
    <Location "/gateway/WEB-INF/*">
        AllowOverride None
        deny from all
    </Location>

    <Location "/gateway/META-INF/*">
        AllowOverride None
        deny from all
    </Location>
    #
    # Use Directory too. On Windows, Location doesn't work unless case matches
    #
    <Directory "C:/Java/Apache/Jakarta/tomcat-4.1.19/webapps/gateway/WEB-INF/">
        AllowOverride None
        deny from all
    </Directory>

    <Directory "C:/Java/Apache/Jakarta/tomcat-4.1.19/webapps/gateway/META-INF/">
        AllowOverride None
        deny from all
    </Directory>

    JkMount /gateway/extend/*  ajp13
    JkMount /gateway/update/*  ajp13
    JkMount /gateway/link/*  ajp13
    JkMount /gateway/delete/*  ajp13
    JkMount /gateway/*.jsp  ajp13
    JkMount /gateway/create/*  ajp13
    JkMount /gateway/retrieve/*  ajp13

    #################### localhost:/webdav ####################

    # Static files 
    Alias /webdav "C:/Java/Apache/Jakarta/tomcat-4.1.19/webapps/webdav"

    <Directory "C:/Java/Apache/Jakarta/tomcat-4.1.19/webapps/webdav">
        Options Indexes FollowSymLinks
        DirectoryIndex index.jsp index.html index.htm 
    </Directory>


    # Deny direct access to WEB-INF and META-INF
    #
    <Location "/webdav/WEB-INF/*">
        AllowOverride None
        deny from all
    </Location>

    <Location "/webdav/META-INF/*">
        AllowOverride None
        deny from all
    </Location>
    #
    # Use Directory too. On Windows, Location doesn't work unless case matches
    #
    <Directory "C:/Java/Apache/Jakarta/tomcat-4.1.19/webapps/webdav/WEB-INF/">
        AllowOverride None
        deny from all
    </Directory>

    <Directory "C:/Java/Apache/Jakarta/tomcat-4.1.19/webapps/webdav/META-INF/">
        AllowOverride None
        deny from all
    </Directory>

    JkMount /webdav/*.jsp  ajp13

    #################### localhost:/examples ####################

    # Static files 
    Alias /examples "C:/Java/Apache/Jakarta/tomcat-4.1.19/webapps/examples"

    <Directory "C:/Java/Apache/Jakarta/tomcat-4.1.19/webapps/examples">
        Options Indexes FollowSymLinks
        DirectoryIndex index.html index.htm index.jsp 
    </Directory>


    # Deny direct access to WEB-INF and META-INF
    #
    <Location "/examples/WEB-INF/*">
        AllowOverride None
        deny from all
    </Location>

    <Location "/examples/META-INF/*">
        AllowOverride None
        deny from all
    </Location>
    #
    # Use Directory too. On Windows, Location doesn't work unless case matches
    #
    <Directory "C:/Java/Apache/Jakarta/tomcat-4.1.19/webapps/examples/WEB-INF/">
        AllowOverride None
        deny from all
    </Directory>

    <Directory "C:/Java/Apache/Jakarta/tomcat-4.1.19/webapps/examples/META-INF/">
        AllowOverride None
        deny from all
    </Directory>

    JkMount /examples/jsp/security/protected/j_security_check  ajp13
    JkMount /examples/snoop  ajp13
    JkMount /examples/servlet/*  ajp13
    JkMount /examples/CompressionTest  ajp13
    JkMount /examples/*.jsp  ajp13
    JkMount /examples/servletToJsp  ajp13
    JkMount /examples/SendMailServlet  ajp13

    #################### localhost:/widgetweb ####################

    # Static files 
    Alias /widgetweb "C:/Java/Apache/Jakarta/tomcat-4.1.19/webapps/widgetweb"

    <Directory "C:/Java/Apache/Jakarta/tomcat-4.1.19/webapps/widgetweb">
        Options Indexes FollowSymLinks
        DirectoryIndex index.html index.htm index.jsp 
    </Directory>


    # Deny direct access to WEB-INF and META-INF
    #
    <Location "/widgetweb/WEB-INF/*">
        AllowOverride None
        deny from all
    </Location>

    <Location "/widgetweb/META-INF/*">
        AllowOverride None
        deny from all
    </Location>
    #
    # Use Directory too. On Windows, Location doesn't work unless case matches
    #
    <Directory "C:/Java/Apache/Jakarta/tomcat-4.1.19/webapps/widgetweb/WEB-INF/">
        AllowOverride None
        deny from all
    </Directory>

    <Directory "C:/Java/Apache/Jakarta/tomcat-4.1.19/webapps/widgetweb/META-INF/">
        AllowOverride None
        deny from all
    </Directory>

    JkMount /widgetweb/Search  ajp13
    JkMount /widgetweb/Controller  ajp13
    JkMount /widgetweb/ViewFile  ajp13
    JkMount /widgetweb/Logout  ajp13
    JkMount /widgetweb/Logon  ajp13
    JkMount /widgetweb/ExecuteCommand  ajp13
    JkMount /widgetweb/*.jsp  ajp13
    JkMount /widgetweb/CreateUser  ajp13

    #################### localhost:/tomcat-docs ####################

    # Static files 
    Alias /tomcat-docs "C:/Java/Apache/Jakarta/tomcat-4.1.19/webapps/tomcat-docs"

    <Directory "C:/Java/Apache/Jakarta/tomcat-4.1.19/webapps/tomcat-docs">
        Options Indexes FollowSymLinks
        DirectoryIndex index.html index.htm index.jsp 
    </Directory>


    # Deny direct access to WEB-INF and META-INF
    #
    <Location "/tomcat-docs/WEB-INF/*">
        AllowOverride None
        deny from all
    </Location>

    <Location "/tomcat-docs/META-INF/*">
        AllowOverride None
        deny from all
    </Location>
    #
    # Use Directory too. On Windows, Location doesn't work unless case matches
    #
    <Directory "C:/Java/Apache/Jakarta/tomcat-4.1.19/webapps/tomcat-docs/WEB-INF/">
        AllowOverride None
        deny from all
    </Directory>

    <Directory "C:/Java/Apache/Jakarta/tomcat-4.1.19/webapps/tomcat-docs/META-INF/">
        AllowOverride None
        deny from all
    </Directory>

    JkMount /tomcat-docs/*.jsp  ajp13

    #################### localhost:/axis ####################

    # Static files 
    Alias /axis "C:/Java/Apache/Jakarta/tomcat-4.1.19/webapps/axis"

    <Directory "C:/Java/Apache/Jakarta/tomcat-4.1.19/webapps/axis">
        Options Indexes FollowSymLinks
        DirectoryIndex index.html index.jsp index.jws 
    </Directory>


    # Deny direct access to WEB-INF and META-INF
    #
    <Location "/axis/WEB-INF/*">
        AllowOverride None
        deny from all
    </Location>

    <Location "/axis/META-INF/*">
        AllowOverride None
        deny from all
    </Location>
    #
    # Use Directory too. On Windows, Location doesn't work unless case matches
    #
    <Directory "C:/Java/Apache/Jakarta/tomcat-4.1.19/webapps/axis/WEB-INF/">
        AllowOverride None
        deny from all
    </Directory>

    <Directory "C:/Java/Apache/Jakarta/tomcat-4.1.19/webapps/axis/META-INF/">
        AllowOverride None
        deny from all
    </Directory>

    JkMount /axis/servlet/AxisServlet  ajp13
    JkMount /axis/servlet/AdminServlet  ajp13
    JkMount /axis/SOAPMonitor  ajp13
    JkMount /axis/services/*  ajp13
    JkMount /axis/*.jsp  ajp13
    JkMount /axis/*.jws  ajp13

    #################### localhost:/manager ####################

    # Static files 
    Alias /manager 
"C:/Java/Apache/Jakarta/tomcat-4.1.19/webapps/../server/webapps/manager"

    <Directory 
"C:/Java/Apache/Jakarta/tomcat-4.1.19/webapps/../server/webapps/manager">
        Options Indexes FollowSymLinks
        DirectoryIndex index.html index.htm index.jsp 
    </Directory>


    # Deny direct access to WEB-INF and META-INF
    #
    <Location "/manager/WEB-INF/*">
        AllowOverride None
        deny from all
    </Location>

    <Location "/manager/META-INF/*">
        AllowOverride None
        deny from all
    </Location>
    #
    # Use Directory too. On Windows, Location doesn't work unless case matches
    #
    <Directory 
"C:/Java/Apache/Jakarta/tomcat-4.1.19/webapps/../server/webapps/manager/WEB-INF/">
        AllowOverride None
        deny from all
    </Directory>

    <Directory 
"C:/Java/Apache/Jakarta/tomcat-4.1.19/webapps/../server/webapps/manager/META-INF/">
        AllowOverride None
        deny from all
    </Directory>

    JkMount /manager/list  ajp13
    JkMount /manager/serverinfo  ajp13
    JkMount /manager/deploy  ajp13
    JkMount /manager/sessions  ajp13
    JkMount /manager/reload  ajp13
    JkMount /manager/html/*  ajp13
    JkMount /manager/resources  ajp13
    JkMount /manager/start  ajp13
    JkMount /manager/stop  ajp13
    JkMount /manager/install  ajp13
    JkMount /manager/*.jsp  ajp13
    JkMount /manager/roles  ajp13
    JkMount /manager/remove  ajp13
    JkMount /manager/undeploy  ajp13
</VirtualHost>

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to