Forum Discussion
Angelina_Van_Ry
Nimbostratus
Jul 17, 2017HTTP redirect iRule overriding all other subdirectories
Hello all,
I am attempting to have anything that goes to contoso.com/folder contoso.com/other to go to their respective pools but I would like to have requests going to contoso.com go to . I have a...
Ryannnnnnnnn
Altocumulus
Jul 18, 2017Heya,
Could you combine the three rules into something like the following?
when HTTP_REQUEST {
if { [string tolower [HTTP::host]] equals "www.contoso.com" } {
if { [string tolower [HTTP::uri]] starts_with "/folder" } {
pool Contoso_Folder_Pool
} elseif { [string tolower [HTTP::uri]] starts_with "/other" } {
pool Contoso_Other_Pool
} else {
HTTP::redirect "https://www.newwebsite.com"
}
}
}
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