Forum Discussion
Gregt_33960
Nimbostratus
May 13, 2008Masking or Redirect?
Hello,
I am hoping some one can help me. I multiple application environments running (test, train, dev, etc..) on a group of web servers. To get to each environment, the client ...
Gregt_33960
Nimbostratus
May 13, 2008CB,
Thank you for the information. Unfortunately the code did not work as the F5 complained about invalid syntax and statements. But I took your logic and applied to my exiting rules and made considerable progress... As it turns out my pgLogin.jsp makes several HTTP requests with that URI variable (dev, test, train) for images and such, which partially broke my web page. I then inserted a nested if statement to indicate that if the initial request ends with the URI variable (test, train, dev) go to the Login page, otherwise keep loading.
when HTTP_REQUEST {
log local0. "Current URI: [HTTP::uri]"
if {[HTTP::uri] starts_with "/test" }{
if {[HTTP::uri] ends_with "/test" }{
HTTP::uri "/test/jsp/common/pgLogin.jsp"
}
pool state_test_pool
} elseif {[HTTP::uri] starts_with "/dev"}{
if {[HTTP::uri] ends_with "/dev" }{
HTTP::uri "/dev/jsp/common/pgLogin.jsp"
}
pool state_dev_pool
} elseif {[HTTP::uri] starts_with "/train"}{
if {[HTTP::uri] ends_with "/train" }{
HTTP::uri "/train/jsp/common/pgLogin.jsp"
}
pool state_train_pool
}
}
I hope this makes sense..if I might ask, is there an easier way to write this? it seems kind of clugy at best
thanks again,
Greg
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)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