Local traffic policies and irules together
Problem this snippet solves: Local traffic policies are very useful to define URL-based redirection, virtual servers and pool assignments, host header rewriting...
But some actions can't be done w...
Updated Jun 06, 2023
Version 2.0Stanislas_Piro2
Cumulonimbus
Joined January 04, 2011
mawan_revera
Oct 06, 2019Altostratus
Hi - i have a Question -
i have a policy that does a redirect - meaning if URI path is / redirect to /abc
for maintenance window i have a i rule that detects time and should redirect to a maintenance page
but the rule gives "Multiple redirect/respond invocations not allowed" -- how can i resolve this - meaning execute this irule
set static::start_date "2019-05-05 10:09"
set static::end_date "2019-05-05 10:10"
set static::start [clock scan $static::start_date]
set static::end [clock scan $static::end_date]
}
when HTTP_REQUEST timing on {
set now [clock seconds]
if { not [class match [IP::client_addr] equals private_net] } {
if {$now > $static::start and $now < $static::end}{
HTTP::redirect "http://mytedirect-maintenance"