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...
newf5learner
Nimbostratus
May 19, 2016I tried this irule.. I irule is executing without any problem, but as its referring to 'host' we are seeing too many redirections error. I'm getting this error on my browser 'The site1.company.com page isn’t working site1.company.com redirected you too many times.'
when HTTP_REQUEST {
if {([HTTP::host] contains "site1.company.com")} {
HTTP::redirect"https://site1.company.com/USERSITE1"
}
elseif {([HTTP::host] contains "site2.company.com")} {
HTTP::redirect "https://site2.company.com/USERSITE2"
}
elseif {([HTTP::host] contains "site3.company.com")} {
HTTP::redirect "https://site3.company.com/USERSITE3"
}
}
Please suggest how to block these too many re-directions or suggest me with a better irule. thanks.
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