Forum Discussion
Svevak_211593
Nimbostratus
Oct 30, 2018URL forwarding to dedicated nodes
Hello,
I am still very new to iRules, and I am trying to get the code correct for a simple URL redirect. I would like to route certain URL-paths to dedicated servers in the same pool.
For e...
CoolPolishGuy
Nimbostratus
Oct 30, 2018Hello,
You could try doing something like the following code
when HTTP_REQUEST {
if { [HTTP::path] contains "/bar" } {
log local0. "pool_a"
pool server_a
} elseif { [HTTP::path] contains "/foo"}{
log local0. "pool_b"
pool server_b
} else {
log local0. "pool_default"
pool server_default
}
}If you want to redirect to specific node inside the pool then write
node 172.x.x.x XXXXHope it helps
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
