[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1030
  • Last Modified:

mod_jk JkMount

I'm trying to configure a mod_jk connector. I know there are other new connectors such as mod_proxy but mod_jk is already set up so I'd like to continue with it.

I am trying to figure out how to get the link http://domain.com/WPBL/ to work the same as
http://domain.com/WPBL

I may have other directories called WPBL2 or WPBL3 so I can't just use the asterisk after WPBL.
Any thoughts?
LoadModule jk_module modules/mod_jk-latest.so
 
JkWorkersFile "/etc/httpd/conf/workers.properties"
 
JkLogFile "/var/log/httpd/mod_jk.log"
JkLogLevel info
 
#additional
JkShmFile     /var/log/httpd/mod_jk.shm
 
JkLogFile  /var/log/httpd/mod_jk.log
JkLogLevel info
 
# end additional
 
<VirtualHost 192.168.3.172:80>
     ServerName mydomain.com
     ServerAlias mydomain.com
     JkMount /jsp-examples/* tomcat
     JkMount /WPBL/* tomcat
     JkMount /tomcat-manager tomcat
     JkMount /tomcat-manager/* tomcat
     JkMount /manager/* tomcat
</VirtualHost>

Open in new window

0
Hokester
Asked:
Hokester
  • 3
  • 2
1 Solution
 
caterham_wwwCommented:
What about forcing a redirect to /WPBL/? Wouldn't that be the easiest solution? Like [1]. I don't know, if mod_alias runs prior mod_jk - both are registered as "run middle", so if a redirect could be a solution for you, you may give RedirectMatch a try.
[1]
RedirectMatch 301 ^/(WPBL)$ http://example.com/$1/

Open in new window

0
 
objectsCommented:
>      JkMount /WPBL/* tomcat

we use that here for directing all traffic starting with /WPBL to tomcat
Can you explain your problem further

0
 
HokesterAuthor Commented:
objects,
When I type in http://domain.com/WPBL, I get this:
Not Found

The requested URL /WPBL was not found on this server.

However, when I type in http://domain.com/WPBL/ I get my tomcat webapp named WPBL.
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
objectsCommented:
is the not found coming from apache or tomcat?

0
 
objectsCommented:
have you tried adding:

     JkMount /WPBL tomcat

0
 
HokesterAuthor Commented:
Oddly, I had tried this. However now in my file I tried
     JkMount /WPBL/* tomcat
     JkMount /WPBL tomcat

With both of them in there, either works now. Thanks guys for all your help.
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

  • 3
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now