Forum Discussion
m00t
Altostratus
Aug 26, 2021iRule path redirect doesn't work with question mark
Hey everyone! I know this should be simple, but I'm missing something here. We currently use an irule as follows to switch between pools on a single virtual server: when HTTP_REQUEST { ...
spalande
Nacreous
Aug 27, 2021since ?cont= is part of HTTP query instead of uri, iRule would need to look for HTTP::query. You can try below or modify if you need to use switch statment for query as well.
when HTTP_REQUEST {
if { [HTTP::query] starts_with "cont=" }{
pool WEB
return
}
switch -glob [string tolower [HTTP::path]] {
"/en/*" -
"/r/*" -
"/kn/*" -
"/up/*"
{
pool WEB
} default {
pool PRO
}
}
}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
