httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Loic Paturel <guina...@gmail.com>
Subject Re: [users@httpd] Currently facing some reverse proxy issues
Date Wed, 10 Apr 2013 12:25:59 GMT
Hi,
thanks for your answer.
I've tried to put both directives outside my <Location> tags but the
behavior is still the same with this configuration.
At that time, I've to choose whether I configure version1 or version2
inside apache but I can't reach both without re-configuring it.

The link you're providing was the stuff I've first looked at but it seems
that the utilization I want is a particular case...

Loic


2013/4/10 Philip Wigg <phil@philipwigg.co.uk>

> Try removing your ProxyPass and ProxyPassReverse directives from inside
> <Location> directives and just put them directly inside your <VirtualHost>
>
> Then use them as detailed in the docs:-
>
> http://httpd.apache.org/docs/2.2/mod/mod_proxy.html#proxypass
>
> i.e. something like:-
>
> ProxyPass /version_App1/subdirectory http://ipAppServer:port1/subdirectory
> ProxyPassReverse /version_App1/subdirectory http://ipAppServer:port1
> /subdirectory
>
> ProxyPass /version_App2/subdirectory http://ipAppServer:port2/subdirectory
> ProxyPassReverse /version_App2/subdirectory http://ipAppServer:port2
> /subdirectory
>
> Phil.
>
>
> On 9 April 2013 16:14, Loic Paturel <guinawek@gmail.com> wrote:
>
>> Hello there,
>>
>> I'll try to explain my issue as clearly as possible.
>> My architecture looks like this :
>> some web space <---> outside server (apache server) <---> application
>> server
>>
>> I've defined a VirtualHost on some outside server ip:port and then some
>> location inside this VHost. This configuration hosts 2 different locations
>> to be redirected on 2 different applciations on the application server
>> (App1 and App2). Both application are 2 different versions on the same
>> basis.
>> I'd like to be able to redirect the following addresses towards the 2
>> applications according to their versions, such as :
>> https://ip:port/version_App1/subdirectory
>> https://ip:port/version_App2/subdirectory
>>
>> In order to do this, I've created 2 Location such as following :
>> ProxyPreserveHost on
>> <Location /version_App1/subdirectory>
>>     ProxyPass http://ipAppServer:port1/subdirectory
>>     ProxyPassReverse http://ipAppServer:port1/subdirectory
>> </Location>
>> <Location /version_App2/subdirectory>
>>     ProxyPass http://ipAppServer:port2/subdirectory
>>     ProxyPassReverse http://ipAppServer:port2/subdirectory
>> </Location>
>>
>> My issue concerns the response I receive from the application server
>> which always answers with a redirection but omit the version in the
>> response. It answers me as following :
>> https://ip:port
>> /subdirectory/common/loginView.do;jsessionid=C3E6707A5BA4FD393B5E22525F4D764B
>> whereas I expect  :
>> https://ip:port
>> /version/subdirectory/common/loginView.do;jsessionid=C3E6707A5BA4FD393B5E22525F4D764B
>>
>> Could someone help me with the rewriting of the response from the
>> application server, to be able to keep the version inside the url I get as
>> answer from the server and which is viewed by the user ?
>>
>> I hope that I've been clear enough and that this has an easy solution.
>> I've read some topic that I think are related to this, but no solution fit
>> to my issue.
>> Thanks in advance.
>>  Loic
>>
>
>

Mime
View raw message