Thx for the tips, but I have spent to much time trying to configure HAproxy
Half of it is now working, I am able to reach my web server through my HAproxy.
Still do not work for iRedmail.
My config:
frontend email-http
mode http
bind :888 ssl crt /etc/ssl/private/full_certs.crt
option httplog
default_backend email-http
backend email-http
mode http
option httplog
option forwardfor
http-request set-header X-Forwarded-Port %[dst_port]
http-request add-header X-Forwarded-Proto https if { ssl_fc }
option httpchk HEAD /HTTP/1.1\r\nHost:localhost
option http-server-close
server node1 private_ip_number:888 ssl verify none
This is a past and copy from the config who is working for my web server.
Error message:
502 Bad Gateway
The server returned an invalid or incomplete response
From the logs of HAproxy:
Jan 13 21:19:21 proxy haproxy[26767]: ip_number:38224 [13/Jan/2017:21:19:21.881] email-http~ email-http/node1 0/0/34/-1/35 502 205 - - SH-- 1/1/0/0/0 0/0 "GET /SOGo/ HTTP/1.1"
From the server side:
haproxy_ip - - [13/Jan/2017:20:19:16 +0100] "GET /SOGo/ HTTP/1.1" 444 0 "-" "Mozilla/5.0 (Linux; Android 6.0.1; Nexus 5 Build/MMB29T) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/54.0.2840.85 Mobile Safari/537.36"
haproxy_ip - - [13/Jan/2017:20:25:18 +0100] "GET /SOGo/ HTTP/1.1" 444 0 "-" "Mozilla/5.0 (Linux; Android 6.0.1; Nexus 5 Build/MMB29T) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/54.0.2840.85 Mobile Safari/537.36"
Any ideas ??
Thx