Forum Discussion
redirect to https non standard poprt
Hi, the requirement is:
http://virtualip:7777 have to be redirect to https://publicip:44444/abc
I was working with Proxypass adding a datagroup:
- string: virtualip:7777
- value:
it seems that the url redirect it works but is not working the port redirect 44444. The redirect is on port 443. Someone can help ?
- dragonflymr
Cirrostratus
Hi,
Not sure what issue you have. Just attach below iRule to virtual:7777 VS and it should work:
when HTTP_REQUEST { HTTP::redirect https://publicip:44444/abc }
Of course assuming that every request to should be redirected to static URI /abc.
If it's not the case use:
when HTTP_REQUEST { HTTP::redirect https://publicip:44444[HTTP::uri] }
Be aware that HTTP::redirect is always using 302 Found. If you need 301 then you have to use HTTP::respond, something like that:
HTTP::respond 301 Location "Connection" "close"
adding appropriate headers as needed
Piotr
Recent Discussions
Related Content
* 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