@max wrote:
Hello there!
I’m looking for a way to bypass the maintenance page on a backend (when all servers are in maintenance mode).
The solution we found is using
force-persist
but it doesn’t work withoutuse-server
.
And this last option doesn’t enable us to use/test load balancing while in maintenance.The documentation doesn’t mention that
force-persist
need to be used withuse-server
or any other option.
But it tells that it works onfrontend
,backend
andlisten
which, I assume, meansforce-persist
support other options.Any idea how to achieve this with
force-persist
or something else?
What is the exhaustive list of options which can be combined withforce-persist
?Our bypass conditions are requests coming from some IPs or having a cookie set to
true
.
(the bypass can be disabled by the clients using an authorized IP with to the cookie set tofalse
)Here a testing configuration:
defaults mode http option httpclose option redispatch option abortonclose frontend http bind *:80 bind *:443 ssl no-sslv3 crt /etc/pki/tls/certs/app.example.org.pem use_backend app backend app server app-01 app-01:80 maxconn 50 check slowstart 30s server app-02 app-02:80 maxconn 50 check slowstart 30s option httpchk GET /healthcheck HTTP/1.1\r\nHost:\ app.example.org errorfile 503 /data/shared/maintenance/http/503.http force-persist if { always_true }
When all the servers are disabled, this configuration doesn’t bypass the maintenance page.
We still get the503
.
Posts: 3
Participants: 2