Files
mtusi2026lab3/infra/haproxy.cfg
T

36 lines
767 B
INI

global
log stdout format raw local0
maxconn 512
defaults
log global
mode http
option httplog
timeout connect 1s
timeout client 15s
timeout server 12s
timeout check 1s
retries 0
resolvers docker
nameserver dns 127.0.0.11:53
resolve_retries 3
timeout resolve 1s
timeout retry 1s
hold valid 1s
hold obsolete 1s
hold nx 1s
hold timeout 1s
hold refused 1s
frontend public
bind :8080
default_backend api
backend api
balance roundrobin
option httpchk
http-check send meth GET uri /health/ready ver HTTP/1.1 hdr Host api
http-check expect status 200
server-template replica 10 api:8080 check inter 1s fall 2 rise 2 resolvers docker resolve-prefer ipv4 init-addr none