PROXY protocol

Tim Groeneveld tim at timg.ws
Thu Aug 20 07:35:40 UTC 2015


Hey Niko,

---- On Thu, 20 Aug 2015 16:55:42 +1000 Nikolaos Milas<nmilas at noa.gr> wrote ---- 
 > I hope you will be able to provide some basic guidelines on how to  
 > enable/use the new functionality. (I am not very code-literate.) 

Looking through the code, the functionality should not be too hard to
enable using the configuration:

# This is a list of trusted networks... ips are seperated by ", "
# default, empty
haproxy_trusted_networks = 10.1.2.0/24, 10.2.1.0/24

# This is the timeout... in seconds.
# default, 3
# haproxy_timeout = 3

# modify your inet listener's to include haproxy=yes
inet_listener {
    haproxy = yes
}


As for HAProxy, the configuration would look something like this:


listen smtp :25
        mode tcp
        option tcplog
        option smtpchk
        balance roundrobin
        server smtp1 ip.of.server1:25 check-send-proxy check inter 10s send-proxy
        server smtp2 ip.of.server2:25 check-send-proxy check inter 10s send-proxy

Regards,
Tim




More information about the dovecot mailing list