Forum Discussion
Magnum_IP
May 03, 2011Nimbostratus
Routing using the virtual command
I'm having a problem routing traffic using the virtual command on HTTPS and hope that someone can help.
I have everything working on HTTP I just can't get HTTPS to work.
Basically ...
Colin_Walker_12
May 03, 2011Historic F5 Account
Ahhh, I see now.
So what I'd recommend is looking at moving the HTTP::respond line directly into the active members check, rather than performing a redirect first (going off the CodeShare entry you linked).
With the HTTP::respond command you can respond with whatever content you want (much like in the iRule you linked to in the codeshare) without having to redirect.
So basically, if it's viable, put the contents of your maintenance page in your iRule (or in a class that your iRule can reference) then respond with that instead of redirecting.
Like so:
If the all members in the default pool are down, redirect to the maintenance page
if { [active_members [LB::server pool]] < 1 } {
HTTP::respond 200 content [lindex $::maint_index_html_class 0] "Content-Type" "text/html"
}
}
You could add any refresh you want there, or the user could continue to hit refresh as desired, and it should work just fine. This would basically do away with the "/" and "/index cases in the switch.
Does that make sense?
Colin
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