Forum Discussion
Rusty_Hale_8009
Nimbostratus
Apr 05, 2005iRule conversion from 4.X to V9
I have made an attempt to convert an iRule to V9. Could someone please check my syntax? I would really appreciate it. Thanks.
if { [HTTP::host]
rule Image_Rule {
...
JRahm
Admin
Apr 05, 2005I think I missed a bracket or fifty:
rule Image_Rule {
when HTTP_REQUEST
{
if ( [HTTP::host} equals "www.mydomain.com" ) {
if ( [HTTP::uri] contains "jpg" ) {
use pool Image_Svr_80
log "JPG file requested by [IP::client_addr]"
}
elseif ( [HTTP::uri] contains "gif" ) {
use pool Image_Svr_80
log "GIF file requested by [IP::client_addr]"
}
}
else {
use pool Main_Svr_80
log "Default LB Method for [IP::client_addr]"
}
}
}
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