Forum Discussion
Thiyagu_343098
Nimbostratus
Jan 24, 2018iRULE to remove the URI on LB
Hello All,
I'm working on a request to remove the URI from the HTTP request and send the rest of the URL path as it is to the backend server:
for example a request as and it should get routed to bac...
youssef1
Cumulonimbus
Jan 24, 2018Hello Thiyagu,
So, You can rewrite the requested URI before it's sent to the node with something like this:
when HTTP_REQUEST {
if {[HTTP::uri] starts_with "/URI1/"}{
set uri [string range [HTTP::uri] 5 end]
HTTP::uri $uri
log local0. "new URI: https://[HTTP::host]$uri"
}
}
Regards,
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