Forum Discussion
gdoyle
Sep 26, 2018Cirrostratus
Maintenance Page iRule and other iRule Conflicting.
The original maintenance page irule is as follows and works by itself:
priority 400
when HTTP_REQUEST {
if { [active_members /partition/poolname_pool] < 1 } {
HTTP::respond 200 conten...
Lee_Sutcliffe
Sep 26, 2018Nacreous
You can't add a header after you have issued an HTTP::respond command. This will likely be why you get an error you will need to add a
return
after you have issued the response tp make sure the header isn't added (if this is indeed what you want to happen)
I have put the two iRules together as given they are relatively simple, there is no need for them to be separate.
when HTTP_REQUEST {
if {[active_members /partition/poolname_pool] < 1 } {
HTTP::respond 200 content [ifile get "poolname_MaintenancePage_ifile"] noserver "Content-Type" "text/html" "Cache-Control" "no-cache, must-revalidate"
return
}
HTTP::header insert HttpsIndicatorHeader True
}
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