Forum Discussion
Joe_Pipitone
Apr 18, 2012Nimbostratus
Rewrite - is this efficient?
I am trying to rewrite just the domain name itself, while leaving the URI intact. This iRule works, however I am wondering if this is the most efficient way to do this? I'd like to catch bo...
nitass
Apr 18, 2012Employee
what about httpclass?
[root@ve1023:Active] config b virtual bar list
virtual bar {
destination 172.28.19.79:80
ip protocol 6
httpclass myhttpclass
profiles {
http {}
tcp {}
}
}
[root@ve1023:Active] config b profile myhttpclass list
profile httpclass myhttpclass {
defaults from httpclass
pool none
redirect "http://newdomain.com[HTTP::uri]"
hosts {
"olddomain.com"
"www.olddomain.com"
}
}
[root@ve1023:Active] config curl -I http://olddomain.com/something
HTTP/1.0 302 Found
Location: http://newdomain.com/something
Connection: Keep-Alive
Content-Length: 0
[root@ve1023:Active] config curl -I http://www.olddomain.com/something
HTTP/1.0 302 Found
Location: http://newdomain.com/something
Connection: Keep-Alive
Content-Length: 0
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