Forum Discussion
bwilliam
Cirrus
Dec 03, 2015irule To Redirect A Specific Network Going To a URL
I have an office in India and need to send any request from that network for site.domain.com to local.domain.com. If the network is not equal India_Host_Networks then hit site.domain.com. I think I h...
StephanManthey
Nacreous
Dec 03, 2015Hi,
there was a missing parenthesis probably causing the failure to load the iRule:when HTTP_REQUEST {
if { ([class match [IP::client_addr] equals India_Host_Networks]) and ([string tolower [HTTP::host]] equals "site.domain.com") } {
HTTP::redirect " https://local.domain.com/stream/"
}
}
To be on the safe side I added a lower case conversion for the hostname. Just make sure to match versus lower case strings as well, please.
Thanks, StephanHelp 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