Forum Discussion
bvinson_12764
Nimbostratus
Nov 02, 2009Domain Redirect
Hello,
Pretty new to Irules,
How do I,,,
I have a new domain and a old domain that point to the same Web services.
lets call them new.com and old.com
I would like it when users access web.old.com to be redirected to web.new.com. I need the name change because of SSL naming.
Any suggestions?
Many Thanks
You guys are awesome
:D
- The_Bhattman
Nimbostratus
Here is a simple redirection of a domain namewhen HTTP_REQUEST { if {[HTTP::host] eq "web.old.com" } { HTTP::redirect "http://web.new.com/[HTTP::uri]/" } }
- bvinson_12764
Nimbostratus
Thanks for the response; - The_Bhattman
Nimbostratus
I suppose you can do the followingwhen HTTP_REQUEST { if { [HTTP::host] contains "old.com"} { HTTP::redirect http://[getfield [HTTP::host] ".old.com" 1].new.com[HTTP::uri] } }
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