Forum Discussion
adrian_171483
Cirrus
Aug 19, 2015Irule URL matching issue.
Hi I am having an issue with the Irule below on the string matching on the URL.
it seems the word "dev" is being matched by the first clause, and dropping to Pool number 1 instead of going pas...
Alexander_Dube_
Altocumulus
Aug 19, 2015Hi,
you can try to swap both cases. Try to match dev.mysite.com before admindev.mysite.com. This would avoid to match admindev.mysite.com when calling dev.mysite.com
I dont know if a switch is accepting regex as criteria, but with an if you can use the following:
when HTTP_REQUEST {
if { [string tolower [HTTP::host]] matches_regex "^admindev.mysite.com" } {
pool number1
}
if { [string tolower [HTTP::host]] matches_regex "^dev.mysite.com" } {
pool number2
}
Regards
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