Forum Discussion

Mark_Casey_1776's avatar
Mark_Casey_1776
Icon for Nimbostratus rankNimbostratus
Nov 18, 2014

Replicating Apache ProxyPass functionality

Hi,

 

We have a website that has content served by both a Apache server pool and an IIS server pool. The Apache pool serves the majority of the content, however there is some IIS specific stuff. As such we have an apache reverse proxy in place with the following rules:

 

ProxyPass /ThisIsContent/ http://123.123.123.123/ThisIsContent/

 

ProxyPass /ThisIsContent http://123.123.123.123/ThisIsContent/

 

ProxyPass /thisiscontent/ http://123.123.123.123/ThisIsContent/

 

ProxyPass /thisiscontent/ http://123.123.123.123/ThisIsContent/

 

The above pointed to a load balanced barracuda address. (so if it goes to the IIS server based content it goes internet > apache reverse proxy > barracuda > iis server)

 

We're in the process of migrating everything to our F5's.

 

I've tried using ProxyPass (https://devcentral.f5.com/wiki/iRules.proxypassv10.ashx) to no avail. I have virtual servers for both the apache servers and IIS servers. For example:

 

"/ThisIsContent/" := "213.213.213.213/ThisIsContent/"

 

Where 213.213.213.213 is the IIS virtual server.

 

All that occurs is when I go to www.websitename.com/ThisIsContent/ it simply redirects to www.websitename.com.

 

What I suspect is happening in this case is that the IIS servers are configured to listen for the host header value of "www.websitename.com", but it isn't getting that through the proxypass irule. (Removing this host header check is out of the question since there are multiple site addresses on the IIS server.)

 

Is there a way to replicate this with an irule on the F5? And if so how?

 

Thanks.