jj24_43946
Jun 23, 2011Nimbostratus
Help with LocalLB::VirtualServer::add_rule
Hi there,
I'm trying to apply an existing iRule to an existing monitor. Though I don't get an error, I don't see the iRules being applied.
my DS looks like this:
my @VirtualServerRules;
if ( $f5_vs_name =~ m/Https/ ) {
my $VirtualServerRule = {
rule_name => 'HA_https_splash_redirect',
priority => 1
};
push ( @VirtualServerRules, $VirtualServerRule );
$VirtualServerRule = {
rule_name => 'SSL_Renegotiate_Disable',
priority => 1
};
push ( @VirtualServerRules, $VirtualServerRule );
}
else {
my $VirtualServerRule = {
rule_name => 'HA_http_splash_redirect',
priority => 1
};
push ( @VirtualServerRules, $VirtualServerRule );
}
my $soapResponse = $VirtualServer->add_rule
(
SOAP::Data->name(virtual_servers => [$f5_vs_name]),
SOAP::Data->name(rules => @VirtualServerRules),
);
print "iRules for virtual server $f5_vs_name applied successfully\n"
}
Would someone happen to have a perl sample handy for applying irules to monitors?? Thanks a lot!