Forum Discussion
Yaniv_93956
Nimbostratus
Jan 21, 2013Using F5 as a proxy between two websites
Hello Devcentral,
I’m trying to set an IRule to act as a proxy between two websites without changing the URL in the user’s browser.
When user goes to
https://www.site1.com/test ...
What_Lies_Bene1
Cirrostratus
Jan 21, 2013OK, that clears things up somewhat, thanks to Nitass too. Try this which will forward traffic to the site2 Virtual Server after the header replacement;
when HTTP_REQUEST {
if { (([string tolower [HTTP::uri]] starts_with "/test") && ([string tolower [HTTP::host]] equals "www.site1.com")) } {
log local0. "Matched host site1.com and uri /test"
HTTP::header replace Host "www.site2.com"
virtual 'site2-VS-name'
}
}
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects