Forum Discussion
Kevin_Stewart
Oct 17, 2013Employee
Unless you just absolutely need to get rid of the "/webapp" portion of the URI, it would be much simpler to keep it. Here's a slight modification to the first iRule:
when HTTP_REQUEST {
if { [TCP::local_port] equals "8052" } {
if { [HTTP::uri] equals "/" } {
HTTP::redirect "http://[HTTP::host]/webapp"
} else {
HTTP::header replace Host "currenturl.olddomain.local"
}
}
}
This simply changes the Host header and redirects to /webapp if the request URI is blank.