ЛР 3 — балансировка и отказ API-реплики

This commit is contained in:
Риц Дмитрий
2026-11-06 02:45:37 +03:00
parent 0ab3a341aa
commit 6dada9a6d0
34 changed files with 2245 additions and 36 deletions
+37
View File
@@ -0,0 +1,37 @@
global
log stdout format raw local0
nbthread 1
defaults
log global
mode http
option httplog
option http-server-close
timeout http-request 5s
timeout http-keep-alive 5s
timeout connect 500ms
timeout client 10s
timeout server 7s
timeout check 700ms
retries 0
resolvers docker
nameserver embedded 127.0.0.11:53
resolve_retries 2
timeout resolve 500ms
timeout retry 500ms
hold valid 1s
hold obsolete 1s
hold nx 1s
frontend public
bind :8080
default_backend messenger
backend messenger
balance roundrobin
option httpchk
http-check send meth GET uri /health/ready ver HTTP/1.1 hdr Host api
http-check expect status 200
default-server inter 500ms fastinter 250ms downinter 500ms fall 2 rise 2
server-template replica 1-8 api:8080 check resolvers docker resolve-prefer ipv4 init-addr none