This tutorial assumes the server runs Debian 8.

First, install HAProxy.

apt install haproxy

Then, Edit /etc/haproxy/haproxy.cfg.

    ulimit-n  51200

    log global
    mode    tcp
    option  dontlognull
    contimeout 1000
    clitimeout 150000
    srvtimeout 150000

frontend ss-in
    bind *:LOCAL_PORT
    default_backend ss-out

backend ss-out
    server server1 TARGET_IP:TARGET_PORT maxconn 20480

Finally, restart HAProxy.

systemctl restart haproxy.


Setup a shadowsocks relay using HAProxy

Leave a Reply

Your email address will not be published. Required fields are marked *