Forum Discussion
puluck
Cirrus
Oct 16, 2017Redirection of URL without changing the host header
Hello Everyone
I have requirement where i need to send traffic to external blog site based on URI but host header of client browser should display the original URL.
https://www.abc.com/app...
Hygor
Nimbostratus
Oct 16, 2017Using equals in your condition means that the uri should be exactly /apple. If the request is /apple/ it will not trigger the condition. I suggest change the condition to contains or starts_with and use a space after HTTP::uri
when HTTP_REQUEST {
if { [HTTP::uri] contains "/apple" } {
node 193.13.14.5
snat automap
HTTP::header replace Host "ebc.mysite.com"
HTTP::uri /
}
}
Also you can use a rewrite profile to rewrite the uri in question and remove the
HTTP::uri / from the iRule.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