Forum Discussion
Deepak_Nair
Cirrus
Jan 20, 2021HTTPS REDIRECTION : Specific NODE using iRULE
Hi Experts , i am working on one requirement where i need to redirect https://www.example.com needs to redirect to specific NODES ( 8 nos ) based on URI PATH . i have created a layer 7 virtua...
Jan 21, 2021
Hi,
As Daniel stated, the host is in lower case, not upper.
Could you test this irule:
when HTTP_REQUEST {
if {([string tolower [HTTP::host]] equals "test-esb-vip-bma.example.com") } {
if {[HTTP::uri] starts_with "/m2p" }
{
node 10.30.214.1 2783
return
}
if {[HTTP::uri] starts_with "/aps"}
{
node 10.30.230.31 7001
return
}
if {[HTTP::uri] starts_with "/bmx"}
{
node 10.30.214.38 61648
return
}
if {[HTTP::uri] starts_with "/cts"}
{
node 10.30.214.236 4515
return
}
if {[HTTP::uri] starts_with "/mii"}
{
node 10.30.215.174 50000
return
}
if {[HTTP::uri] starts_with "/ampla-bma"}
{
node 10.30.222.43 8889
return
}
if {[HTTP::uri] starts_with "/ampla-bmc"}
{
node 10.38.2.48 8889
return
}
if {[HTTP::uri] starts_with "/iqt-bma"}
{
node 10.30.215.208 8889
return
}
if {[HTTP::uri] starts_with "/iqt-bmc"}
{
node 10.30.222.230 8889
return
}
}
}
Cheers,
Kees
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