mirror of
http://git.haproxy.org/git/haproxy.git/
synced 2025-01-07 12:49:42 +00:00
5cbea6fd41
* added OpenBSD, Linux-2.2 and Linux-2.4 targets to the Makefile * added a Formilux init script * fixed a few timeout bugs * rearranged the task scheduler subsystem to improve performance, add new tasks, and make it easier to later port to librt ; * allow multiple accept() for one select() wake up ; * implemented internal load balancing with basic health-check ; * cookie insertion and header add/replace/delete, with better strings support. * reworked buffer handling to fix a few rewrite bugs, and improve overall performance. * implement the "purge" option to delete server cookies in direct mode. * fixed some error cases where the maxfd was not decreased. * now supports transparent proxying, at least on linux 2.4. * soft stop works again (fixed select timeout computation). * it seems that TCP proxies sometimes cannot timeout. * added a "quiet" mode. * enforce file descriptor limitation on socket() and accept().
80 lines
1.7 KiB
Plaintext
80 lines
1.7 KiB
Plaintext
listen proxy1 0.0.0.0:8000
|
|
mode http
|
|
#mode tcp
|
|
cookie SERVERID insert indirect
|
|
balance roundrobin
|
|
#dispatch 127.0.0.1:3130
|
|
#dispatch 127.0.0.1:31300
|
|
#dispatch 127.0.0.1:80
|
|
#dispatch 127.0.0.1:22
|
|
server tuxlocal 127.0.0.1:80 cookie cookie1 check
|
|
server tuxceleron 10.101.0.1:80 cookie cookie2 check
|
|
#server telnet 127.0.0.1:23
|
|
#server ssh 127.0.0.1:22
|
|
server local 127.0.0.1:3130 cookie cookie3 check
|
|
#server local 127.0.0.1:3130
|
|
#server celeron 10.101.0.1:80 cookie srv1
|
|
#server celeron 10.101.0.1:31300
|
|
#server local 10.101.23.9:31300
|
|
contimeout 3000
|
|
clitimeout 150000
|
|
srvtimeout 150000
|
|
maxconn 60000
|
|
redispatch
|
|
retries 3
|
|
grace 3000
|
|
#rsprep ^Server.* Server:\ IIS
|
|
#rspdel ^Server.*
|
|
#rspadd Set-Cookie:\ mycookie=0;\ path=/
|
|
#rsprep ^(Date:\ )([^,]*)(,\ )(.*) LaDate\ est:\ \4\ (\2)
|
|
|
|
listen proxy1 0.0.0.0:3128
|
|
mode http
|
|
cookie SERVERID indirect
|
|
dispatch 127.0.0.1:8080
|
|
server srv1 127.0.0.1:8080
|
|
#server srv2 192.168.12.3:8080
|
|
contimeout 3000
|
|
clitimeout 450000
|
|
srvtimeout 450000
|
|
maxconn 60000
|
|
redispatch
|
|
retries 3
|
|
grace 3000
|
|
|
|
|
|
listen proxy2 0.0.0.0:3129
|
|
mode http
|
|
transparent
|
|
# dispatch 127.0.0.1:80
|
|
contimeout 3000
|
|
clitimeout 150000
|
|
srvtimeout 150000
|
|
maxconn 60000
|
|
retries 3
|
|
grace 3000
|
|
|
|
# log 10.101.11.1 local1
|
|
# log 10.101.11.1 local2
|
|
|
|
# cliexp ^(.*ASPSESSIONID.*=)(.*) \1FENICGGCBECLFFEEOAEAIFGF
|
|
# cliexp ^(GET.*)(.free.fr)(.*) \1.online.fr\3
|
|
# cliexp ^(POST.*)(.free.fr)(.*) \1.online.fr\3
|
|
# cliexp ^Proxy-Connection:.* Proxy-Connection:\ close
|
|
# srvexp ^(Location:\ )([^:]*://[^/]*)(.*) \1\3
|
|
|
|
listen health 0.0.0.0:3130
|
|
mode health
|
|
clitimeout 1500
|
|
srvtimeout 1500
|
|
maxconn 6000
|
|
grace 0
|
|
|
|
|
|
listen health 0.0.0.0:31300
|
|
mode health
|
|
clitimeout 1500
|
|
srvtimeout 1500
|
|
maxconn 6000
|
|
grace 0
|