Forum Discussion
Gonzalex_330537
Cirrostratus
Would you please post your virtual servers configuration. What TMOS version are you running? Also, what do you mean by 9500 and 9502? I am not very clear why you need an iRule for this? And what do you mean by browsing from the console? Do you mean cli using curl?
Sorry, your question is not very clear to me.
You shouldn't really need an iRule for redirections unless you are running old code or in other specific scenarios. I guess it's the specific scenario here that I don't understand.
jurgenvdmark_14
Oct 30, 2017Nimbostratus
Instead of doing a redirect you should change the response from the server. For Instance you can do something like this:
when HTTP_RESPONSE {
if { [HTTP::is_redirect] } {
Replace absolute path with relative path
HTTP::header replace Location [regsub {https?://[^/]*/} [HTTP::header value Location] "/"]
}
}
This removes the host part of the URI