Forum Discussion
Dbow_21284
Nimbostratus
May 21, 2009HTTPS VIP - Redirect to Maintenace Page
Hey everyone,
Fairly new to F5s, used to the GUI stuff (laught all you want)! Anyway, I have a site that is HTTPS only, and I need to redirect to a maintenance page if all the nodes in...
Dbow_21284
Nimbostratus
May 21, 2009I found this one:
when CLIENT_ACCEPTED {
Set this flag to 1 to decrypt the SSL and send a redirect to the client.
Set to 0 to pass the SSL through without decrypting it.
set maintenance_redirect 1
log local0. "[IP::client_addr]:[TCP::client_port]: Received connection with maintenance flag set to $maintenance_redirect"
Check if the maintenance flag is disabled (set to 0)
if {$maintenance_redirect==0}{
Disable the client SSL profile so the HTTPS traffic is passed through encrypted to the node
SSL::disable
Disable the HTTP profile as we're not going to redirect this request
HTTP::disable
log local0. "[IP::client_addr]:[TCP::client_port]: Maintenance flag is disabled"
}
}
when HTTP_REQUEST {
The HTTP_REQUEST event is only triggered if the maintenance flag is enabled and the client SSL and HTTP profiles are left enabled
Redirect the client
HTTP::redirect https://maintenance.example.com
log local0. "[IP::client_addr]:[TCP::client_port]: Redirecting request" }
But I dont see in the code where it detects if all the pool members are available or not.
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects