Hi,

I'm currently upgrading from postfix 2.9 to 2.10 with haproxy 1.5-dev17

So far, everythink works fine with:
:/etc/haproxy/haproxy.cfg:

frontend ft_smtps
    bind :465
    mode tcp
    default_backend bk_smtps

frontend ft_submission
    bind :587
    mode tcp
    default_backend bk_submission

backend bk_smtps
    mode tcp
    balance source
    stick store-request src
    stick-table type ip size 200k
    server smtps_mailout-vty-001 192.168.100.16:1465 weight 200 check
    server smtps_mailout-vty-002 192.168.100.17:1465 weight 200 check

backend bk_submission
    mode tcp
    balance source
    stick store-request src
    stick-table type ip size 200k
server submission_mailout-vty-001 192.168.100.16:1587 send-proxy weight 200 check server submission_mailout-vty-002 192.168.100.17:1587 send-proxy weight 200 check

So far, everything works as expected between haproxy and postfix as long as I use the submission port.

When using the SSMTP port *and* send-proxy it fails.

The workaround so far has then be to:
:main.cf:
- remove smtpd_upstream_proxy_protocol=haproxy
- remove smtpd_upstream_proxy_timeout=5s
:master.cf:
- add -o smtpd_upstream_proxy_protocol=haproxy
- add -o smtpd_upstream_proxy_timeout=5s

leading to the use og the proxy protocol only for submission but not for SMTPS.

Did I miss something obvious ?

Thanks

Laurent

Reply via email to