Warm tip: This article is reproduced from stackoverflow.com, please click
apache websphere reverse-proxy httpd.conf

WebSphere reverse proxy plugin

发布于 2020-03-31 23:01:25

Hoping someone can give me some advice if possible.

We have a Linux box in our DMZ with the WebSphere plugin. This points to a Windows box running WebSphere Application Server.

httpd config only contains the default virtualhost with no ServerAlias specified. There is a redirect set up in the virtualhost in httpd.conf to forward any requests to service.domain.com to service.domain.com/wascontext1. Plugin-cfg.xml is set up with two uri groups, wascontext1 and wascontext2, but only 1 is actively used.

I want to use the Linux box as a reverse proxy for another application totally separate to WAS. It would have a different domain (i.e. dimsim.domain.com) but point to the same IP.

I was going to add another virtualhost for this but am unsure exactly how the WebSphere plugin will behave with it. From what I understand if I set this up and went to dimsim.domain.com/wascontext1 it would serve the WebSphere content as httpd forwards all requests to the plugin.

Is there a way to tell httpd to not send requests to the WebSphere plugin based on domain name or virtualhost? Or would doing a rewrite on any requests to dimsim.domain.com/wascontext be considered ok?

thanks

jc

EDIT: Thanks for the responses! I'll test changing the virtualhost name in plugin-cfg.xml on our second unused context and let you know how it goes.

Questioner
jcrow
Viewed
61
covener 2020-01-31 20:09

A solution that doesn't require plugin-cfg.xml changes: If you use an Apache-based HTTP server, you can conditionally set the per-request variable "skipwas" to short-circuit the WAS Plugin processing.

e.g.

SetEnvIf Host ^dimsim\.domain\.com$ skipwas=1