Forum Discussion
newf5learner_13
Nimbostratus
May 18, 2016irule to redirect to specific uri..
Hi All,
I need a irule that helps me to redirect users to specific resources / folders on the servers.
I have three servers, all of them hosting sites https://site1.company.com https://site...
Stanislas_Piro2
Cumulonimbus
May 18, 2016Hi,
you redirected all URI, so the redirected may be looping.
when HTTP_REQUEST {
set host [string tolower [HTTP::host]]
if HTTP::uri equals "/" {
switch -glob [string tolower [HTTP::host]] {
"site1.company.com" {HTTP::redirect "/USERSITE1"}
"site2.company.com" {HTTP::redirect "/USERSITE2"}
"site3.company.com" {HTTP::redirect "/USERSITE3"}
}
}
}
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