Abed_AL-R
Nov 05, 2020Cirrostratus
excluding specific uri from datagroup
Hello guys
I'm using this iRule to do redirection with data group:
when HTTP_REQUEST {
if { [class match [string tolower [HTTP::uri]] starts_with myweb_Uri_Data_group] } {
HTTP::redirect "[class match -value [string tolower [HTTP::uri]] starts_with myweb_Uri_Data_group]"
}
}
In the data group I have this uri to be redirected:
/myweb/folder1/coronatime
And I what to exclude this uri from datagroup:
/myweb/folder1/coronatime-xyz
What is the best way to exclude specific uri ?
is it using another "if" on the top with return statement ?
or there is another way?
Does the "return" exits the specific if function or exits all the irule?
Because it's written here that it does not exit from the iRule altogether: https://clouddocs.f5.com/api/irules/return.html
Thanks !!