Forum Discussion
TJ_Vreugdenhil
Cirrus
Dec 06, 2012iRule to replace context root
Hi -
I would like to create an iRule that does some URI routing:
/myenrollments/* to /adminentrollments/*
So essentially, finding [HTTP:host]/myenrollments/{http_uri} and replacing it with [HTTP:host]/adminenrollments[HTTP:uri]
Does anyone have a sample iRule for this?
Thanks!
1 Reply
- hoolio
Cirrostratus
Can you try this?when HTTP_REQUEST { if {[HTTP::uri] starts_with "/myenrollments"}{ HTTP::uri [string map "/myenrollments /adminentrollments" [HTTP::uri]] } }
Aaron
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