Added Custom Error messages
This commit is contained in:
parent
80b49c6185
commit
20b27713bd
9 changed files with 186 additions and 2 deletions
|
|
@ -3,6 +3,7 @@ FROM haproxy:1.8-alpine
|
||||||
RUN apk add --no-cache bash
|
RUN apk add --no-cache bash
|
||||||
|
|
||||||
COPY entrypoint.sh /
|
COPY entrypoint.sh /
|
||||||
|
COPY assets/errors-custom/* /etc/haproxy/errors-custom/
|
||||||
|
|
||||||
ENTRYPOINT [ "/entrypoint.sh" ]
|
ENTRYPOINT [ "/entrypoint.sh" ]
|
||||||
CMD ["haproxy", "-f", "/usr/local/etc/haproxy/haproxy.cfg"]
|
CMD ["haproxy", "-f", "/etc/haproxy/haproxy.cfg"]
|
||||||
25
assets/errors-custom/400.http
Normal file
25
assets/errors-custom/400.http
Normal file
File diff suppressed because one or more lines are too long
25
assets/errors-custom/403.http
Normal file
25
assets/errors-custom/403.http
Normal file
File diff suppressed because one or more lines are too long
25
assets/errors-custom/408.http
Normal file
25
assets/errors-custom/408.http
Normal file
File diff suppressed because one or more lines are too long
25
assets/errors-custom/500.http
Normal file
25
assets/errors-custom/500.http
Normal file
File diff suppressed because one or more lines are too long
25
assets/errors-custom/502.http
Normal file
25
assets/errors-custom/502.http
Normal file
File diff suppressed because one or more lines are too long
25
assets/errors-custom/503.http
Normal file
25
assets/errors-custom/503.http
Normal file
File diff suppressed because one or more lines are too long
25
assets/errors-custom/504.http
Normal file
25
assets/errors-custom/504.http
Normal file
File diff suppressed because one or more lines are too long
|
|
@ -18,6 +18,14 @@ defaults
|
||||||
timeout client 10s
|
timeout client 10s
|
||||||
timeout server 10m
|
timeout server 10m
|
||||||
|
|
||||||
|
errorfile 400 /etc/haproxy/errors-custom/400.http
|
||||||
|
errorfile 403 /etc/haproxy/errors-custom/403.http
|
||||||
|
errorfile 408 /etc/haproxy/errors-custom/408.http
|
||||||
|
errorfile 500 /etc/haproxy/errors-custom/500.http
|
||||||
|
errorfile 502 /etc/haproxy/errors-custom/502.http
|
||||||
|
errorfile 503 /etc/haproxy/errors-custom/503.http
|
||||||
|
errorfile 504 /etc/haproxy/errors-custom/504.http
|
||||||
|
|
||||||
global
|
global
|
||||||
log 127.0.0.1 local0 notice
|
log 127.0.0.1 local0 notice
|
||||||
maxconn 2000
|
maxconn 2000
|
||||||
|
|
@ -84,7 +92,7 @@ backend srv_80_$COUNT
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
HAPROXY_CFG="/usr/local/etc/haproxy/haproxy.cfg"
|
HAPROXY_CFG="/etc/haproxy/haproxy.cfg"
|
||||||
FRONTEND=""
|
FRONTEND=""
|
||||||
BACKEND=""
|
BACKEND=""
|
||||||
TURN="FB"
|
TURN="FB"
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue