TWSS_18275
Feb 21, 2008Nimbostratus
Nested iRules
Is it possible to call an iRule from within an iRule?
For example:
rule rule_serv_id_https
when HTTP_RESPONSE {
set serv_ip [getfield [IP::server_addr] "." 3]
append serv_ip "." [getfield [IP::server_addr] "." 4]
HTTP::header insert Server_Id $serv_ip
}
}
rule rule_bot_https {
when HTTP_REQUEST {
if { [matchclass [string tolower [HTTP::header User-Agent]] contains $::bots] } {
HTTP::header insert Is_Bot "Yes"
persist none
pool pool_bot_1_https
}
}
rule rule_serv_id_https
}