How can I configure a reverse proxy for same context roots
I am trying configure reverse proxy for jazz 3.0.1 with old the context roots:
RM server: https://rm.ca.sbrf.ru:9443/rdm
QM server: https://qm.ca.sbrf.ru:9443/jazz
I tried to use ProxyPass \jazz for https://ccm.ca.sbrf.ru:9443/jazz and ProxyPass \jazz for https://qm.ca.sbrf.ru:9443/jazz,
but but it does't work.
Are there any example or trick in configuring HTTP server to treat same context roots in different way?
2 answers
I don't fully understand your question, probably because the information on QM is missing.
However, this is what I know about feasibility of reverse proxies. See https://jazz.net/library/article/831 for more topology information and the library for additional content.
-
If you want to use a reverse proxy, all applications have to be set up with the same URL prefix. For example https://qualifiedhostname:port/ .
- You can use the postfix to pass the requests to the dedicated server. To be able to do that, the postfix (in Jazz the context root), needs to be different.
-
If you do a new install, you can follow the infocenter topic on installing with a different context root. You would install e.g as ccm1, ccm2,..... This then allows to use https://qualifiedhostname:port/ccm1, https://qualifiedhostname:port/ccm2 as public URI that can be distinguished.
I am not sure if there is a solution for the setup you use. The only way I see would be very tricky, using server rename and changing the context root of the applications, plus an install with a different context root and manually moving the restore data into the new install. Server rename does not support this kind of scenario today, for what I am aware of and I would not suggest to go down this route today.
Comments
Some clarifications after Ruslan:
Current Public URI for ccm and qm are:
It was upgraded from 2.x so we have to use "old" context roots.
We would like to migrate to enterprise toipology from existing all-on-one-machine (and no proxy) deployment. CLM version is 3.x so we cannot change Public URI before moving to enterprise topology with reverse proxy.
Question is if there's a way to setup reverse proxy to distinguish incoming requests with same context root. All examples describe "classic" case with default, different context roots for each application.
I am not aware of a way to do this. For one thing the ports are different and the context root is not. You can't have the same proxy listen to two different posts, can you? So you would need two seperate proxies serving the original public URI's. What would you hope to gain with this?
You would have to change the port as well as the context root. I can imagine this could be done with a server rename, however this scenario is not yet supported by server rename as far as I can tell. As mentioned server rename is only available in 4.x. In addition it would be probably require quite complex install and backup/restore strategies to change the context roots during server rename.
Without server rename, which is not available in 3.x, you would not even be able to install two applications with the same context root into the same application server. So I don't see any possible scenario. Similar requests I have seen in the past were not pursued for the reasons above.
You might want to work with your IBM contacts or support if there is a supported scenario, but I doubt it.
Example:
ProxyPass \ccm https://ccm.ca.sbrf.ru:9443/jazz
ProxyPass \qm https://qm.ca.sbrf.ru:9443/jazz
Am i understand correctly, that before configuring reverse proxy i need change the context roots for the target servers(CCM server: https://ccm.ca.sbrf.ru:9443/jazz and QM server: https://qm.ca.sbrf.ru:9443/jazz) ?
Can't i to use “rewrite” rules, other Apache tricks or this configuration?