Forum Discussion
lisiecki_54902
Nimbostratus
Jun 09, 2009https redirect to pool based on uri
I have looked though many examples. I recieve an https request and I need to forward to a pool based on uri:
when HTTP_REQUEST {
if { [HTTP::uri] starts_with "/thing1" } {
...
lisiecki_54902
Nimbostratus
Jun 15, 2009solution,
thanks for the help from the forum and support, while the F5 will send to the port, the Sun App server needs to see the port in the header.
when HTTP_REQUEST {
if { [HTTP::uri] starts_with "/thing1" } {
HTTP::header replace Host a.b.c:1082
pool thing1pool
}
if { [HTTP::uri] starts_with "/thing2" } {
HTTP::header replace Host a.b.c:1080
pool thing2pool
}
if { [HTTP::uri] equals "/" } {
HTTP::redirect https://a.b.c/thing1
}
elseif { [string tolower [HTTP::host]] equals "a.b.c"} {
HTTP::header replace Host a.b.c:1080
pool thing2pool
}
}
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