Forum Discussion
Pete_73764
Nimbostratus
Jun 03, 2008Website redirect
Is it possible to have an Irule inspect the header and redirect based on url? For example a request comes in for www.orange.com on a vip and gets directed to its pool, but another request for www.gre...
hoolio
Cirrostratus
Jun 04, 2008A switch would also work nicely:
when HTTP_REQUEST {
Select the pool based on the host header value
switch [string tolower [HTTP::host]] {
www.orange.com {
pool orangepool
}
www.green.com {
pool greenpool
}
default {
pool defaultpool
}
}
}
If you want to specify a VIP rather than a pool, you can use the 'virtual' command in 9.4 or later (Click here). Just replace pool POOL_NAME with vip VIP_NAME.
Aaron
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