Forum Discussion
Frank_Cai_30145
Nimbostratus
Dec 02, 2016an iRules to redirect http traffic
Dear all
external user can access http://123.10.1.1:9090/abc , we need to load balance between two internal server 10.173.20.13:8080/abc and 10.173.20.14:8080/abc
and there is another service http:...
Vijay_E
Cirrus
Dec 05, 2016Assuming that you have configured default pool within the VS configuration, you can use an iRule like this modified from @jhass' iRule:
when CLIENT_ACCEPTED {
set DEFAULT_POOL [LB::server pool]
}
when HTTP_REQUEST {
if {[string tolower[HTTP::uri]] starts_with "/abc"} {
pool pool1
} elseif {[string tolower[HTTP::uri]] starts_with "/def"} {
pool pool2
} else {
pool DEFAULT_POOL
}
}
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