frontend http
bind *:80
bind *:443 ssl crt /etc/haproxy/cert.pem
redirect scheme https code 301 if !{ ssl_fc }
reqadd X-Forwarded-Proto:\ http
reqadd X-Forwarded-Proto:\ https
mode http
errorfile 503 /etc/haproxy/50x.http
default_backend web-backend
backend web-backend
balance roundrobin
server web1 117.53.44.123:8080 check