I have a simple VS with 1 pool member, when the user goes to the URL (https://myurl.com) they are redirected to the full path (https://myurl.com/uri/login.jsp) just fine and are presented with a login prompt. After the enter their credentials and click the login button the server replies with the FQDN of the server (https://server01.local.domain/uri/redirectToLogin.jsp).
I have tried to modify the following irule to try to fit my need and while it does change the URL from the server name to the correct URL it does not work.
So then i found another simpler (seemed) but this ones did not change the URL at all
Can anyone tell me what i am doing wrong or suggest a better way of doing this?
On a normal day i would tell them to change the server response (because i can see on my capture the server is sending the re-direct) but we are on a tight deadline and i need to find a workaround before Friday.
It might be quicker to just fix the backend, actually.
The shorter irule does not make sense, as "Host:" is a request header.
Any details as to how it does not work?
The URL does not change from server1.local.domain/uri to myurl.com/uri
You can capture the server response from your browser by going "Tools" -> "Web Developer" -> "network" to see what is sent back to the browser.
Your irule only fixes HTTP redirects sent by the backend.
Issue is resolved... had to get mgmt involved but admin changed backend and issue is now resolved.
Just as an FYI the short iRule did change the URL from server1.local.domain/uri to myurl.com/uri, the reason it didn't work the first time i tried was because i had an extra character on mine so it wasn't matching. After i fixed it it worked but the site was not reachable due to the CF with the server config. Once the admin fixed the config the site worked and the iRule was not needed.