4
0

haproxy.conf 758 B

1234567891011121314151617181920212223242526272829303132
  1. global
  2. stats socket /var/run/haproxy/admin.sock mode 660 level admin
  3. log stdout local0
  4. frontend cleartext_frontend
  5. bind 0.0.0.0:8080
  6. timeout client 10s
  7. stats enable
  8. stats uri /stats
  9. stats refresh 30s
  10. log global
  11. option httplog
  12. option dontlognull
  13. log-format "[%t] %ci:%cp -> BACKEND:%b/%s | %HM %HU | Status:%ST | Bytes:%B"
  14. mode http
  15. use_backend be_olivetin if { hdr(Host) -i -m beg olivetin.example.com }
  16. backend be_olivetin
  17. mode http
  18. timeout connect 10s
  19. timeout server 10s
  20. timeout tunnel 1h
  21. option http-server-close
  22. http-request set-header X-Forwarded-User "Alice"
  23. http-request set-header X-Forwarded-Group "Group1,Group2"
  24. server olivetinServer 127.0.0.1:1337 check