tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dean Searle" <>
Subject RE: HTTPS with Apache 2.0.48 and Tomcat 5.0.16
Date Tue, 03 Feb 2004 14:13:54 GMT
Here is part of my httpd.conf for and Apache2, Tomcat 4.1.29 and mod_jk2 setup. This is only
for the Virtual host part. Assuming you have everyhting else loading correctly it should work.


	Redirect permanent /

	DocumentRoot z:/tomcattest/webapps
	ErrorLog z:/tomcattest/logs/domain_error.log
	CustomLog z:/tomcattest/logs/domain_access.log common
	SSLEngine On
	SSLCertificateFile		conf/ssl/domain.crt
	SSLCertificateKeyFile		conf/ssl/domain.key.unsecure
	SSLCACertificateFile 		conf/ssl/intermediate.crt

	<Location /rvdc>
	<Location "/domain/WEB-INF/*">
		AllowOverride None
		deny from all
	<Location /webapps/*.jsp>
		JkUriSet group ajp13:localhost:8109

The JkMount directives only work for mod_jk. Mod_jk2 requires a whole new set of directives
to work. Following is my server.xml and that should help.


# only at beginnin. In production uncomment it out


# Example socket channel, override port and host.



#info=The jni channel, used if tomcat is started inprocess

info=Status worker, displays runtime information

#info=Parameters used to load a JVM in the server process

#info=Command to be executed by the VM on startup. This one will start tomcat.

#info=Command to be executed by the VM on shutdown. This one will stop tomcat.

# Define the worker
# First Web Application Worker

# Second Web Application Worker

# Third Web Application Worker

 Uri mapping

info=Display status information and checks the config file for changes.


***This is the only section you need to make sure is enabled. Leave everything else alone.
Note: the port designated here might be different than yours. You can use any port you want
here as long as you use the same port in the httpd.conf and the file.****

 <!-- Define a Coyote/JK2 AJP 1.3 Connector on port 8009 -->
    <Connector className="org.apache.coyote.tomcat4.CoyoteConnector"
               port="8109" minProcessors="5" maxProcessors="75"
               enableLookups="true" redirectPort="8443"
               acceptCount="10" debug="0" connectionTimeout="0"

***I hope that this helps you out.***


-----Original Message-----
From: Oscar Carrillo []
Sent: Mon 2/2/2004 4:04 PM
To: Tomcat Users List;
Subject: Re: HTTPS with Apache 2.0.48 and Tomcat 5.0.16

The JkMount directives tell Apache to pass these request thru the 
Connector to Tomcat.

I do this very same thing for jWebMail, cause I don't want it accessible 
thru http, only https. Here's my ssl.conf config section for it:
<VirtualHost _default_:443>
#Other stuff about your ssl host

    # Static files
    Alias /webmail "/usr/local/tomcat/webapps/webmail"

    <Directory "/usr/local/tomcat/webapps/webmail">
        Options Indexes FollowSymLinks
        DirectoryIndex index.jsp

    <Location "/webmail/META-INF/*">
        AllowOverride None
        deny from all

    <Location "/webmail/WEB-INF/*">
        AllowOverride None
        deny from all

    JkMount /webmail/do/*  ajp13
    JkMount /webmail/*.jsp  ajp13
    JkMount /webmail/WebMail  ajp13
    JkMount /webmail/WebMail/*  ajp13

Does that help? BTW, this is all on my site but there's quite a bit of stuff there that you
can miss it.


On Mon, 2 Feb 2004, Ralf Schneider wrote:

> Am Montag, 2. Februar 2004 21:26 schrieb Oscar Carrillo:
> > I believe you need to setup a VirtualHost section in httpd.conf even if
> > you don't really need Virtual Hosting.
> I did that.
> > Also try Redirecting the whole site. I'm not sure if I've tried just the
> > webapp. I'm not sure if you need to compile the rewrite module for the
> > redirect, but I don't think so.
> >
> > #httpd.conf VirtualHost section of myhost.mydomain
> > Redirect / https://myhost.mydomain/mywebapp
> But I don't want to do this with the whole site, because there are parts that 
> should be accessible with normal HTTP.
> > Also, you can't include the mod_jk configuration. You must put the mount
> > commands explicitly in each virtual host. If you include the modjk conf
> > file "Include mod_jk.conf", then it will be global and all hosts will get
> > access. This is likely your problem especially if you haven't put mod_jk
> > mount commands in "ssl.conf".
> I did not put any JKMount statements in ssl.conf. Which do I need? Something 
> like this:
> JKMount /demo_02/* ajp13
> Or anything else? I think I did not understood correctly what this JkMount 
> does.
> Ralf.
> ---------------------------------------------------------------------
> To unsubscribe, e-mail:
> For additional commands, e-mail:

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message