Forum Discussion
Stanislas_Piro2
Aug 11, 2015Cumulonimbus
this irule execute HTTP::respond command.
if one of following irule execute a command modifying the HTTP context like HTTP::header insert, it will raise a TCL error and generate a connection reset.
that's why I proposed to disable HTTP_REQUEST event...
the irule should be:
when HTTP_REQUEST {
if { [HTTP::uri] eq "/logo.gif" } {
HTTP::respond 200 content [ifile get logo.gif]
} elseif { [HTTP::host] contains "services" and [HTTP::uri] contains "svcpage" } {
HTTP::respond 200 content [ifile get Maintenance-page-web]
} else { discard }
event disable
}
when HTTP_RESPONSE {
to enable HTTP_REQUEST Event for following requests
event HTTP_REQUEST enable
}
I remove the wildcard in the second statement.