Forum Discussion
ppater_73099
Nimbostratus
Jul 08, 2013URL forward
Hello,
Can someone help me with creating an irule?
I want to foward the following.
http://www.example.com/test1
to
http://test1.example.com
Thanks
Best Regar...
nitass
Employee
Jul 08, 2013e.g.
[root@ve10:Active] config b virtual bar list
virtual bar {
snat automap
destination 172.28.19.252:80
ip protocol 6
rules myrule
profiles {
http {}
tcp {}
}
}
[root@ve10:Active] config b rule myrule list
rule myrule {
when HTTP_REQUEST {
if { [HTTP::host] eq "www.example.com" and [HTTP::uri] eq "/test1" } {
HTTP::redirect "http://test1.example.com"
}
}
}
[root@ve10:Active] config curl -i http://www.example.com/test1
HTTP/1.0 302 Found
Location: http://test1.example.com
Server: BigIP
Connection: Keep-Alive
Content-Length: 0
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)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