Forum Discussion
skkg_111590
Nov 12, 2010Nimbostratus
need irule help
I need help as I am new to irule
When user tries to go to
1. http://abc.com/secure/* ----------it should redirect to https://abc.com./secure/* --works all fine.
when HTTP...
SSHSSH
I'd use 1 iRule - would this work? Oh and I've found a neat src ip irule example from hoolio. I take it you'll be forwarded a specific src ip to a different pool altogether? If so try this.
when CLIENT_ACCEPTED {
Save VS default pool name
set default_pool [LB::server pool]
Check if client IP is 1.1.1.1
if {[IP::addr [IP::client_addr] equals 1.1.1.1]}{
Select the second pool
pool second_pool
}
}
when HTTP_REQUEST {
switch [string tolower [URI::host [HTTP::uri]]] {
youtube.com -
www.youtube.com -
4shared.com -
www.4shared.com -
rapidshare.com -
www.rapidshare.com {
pool cache_pool
}
default {
pool $default_pool
}
}
}
N