Hello
I am facing difficulties setting up SSL termination for my HAProxy instance and need some assistance. The issue arises when I try to serve HTTPS traffic through HAProxy while forwarding requests to backend servers using HTTP. Despite following several guides, the SSL handshake seems to fail, and I get browser errors indicating that the connection isnāt secure.
Hereās my setup:
- HAProxy is running on a Ubuntu 22.04 server.
- Iāve installed a Letās Encrypt SSL certificate, and the
.pem
file is placed in the correct directory. - Frontend is configured to listen on port 443 with the SSL certificate. Backend servers are running HTTP on port 80.
Below is a snippet of my configuration file:
frontend https_front
bind *:443 ssl crt /etc/haproxy/certs/certificate.pem
default_backend http_back
backend http_back
server server1 192.168.1.10:80 check
Whenever I attempt to access the site, the browser throws a āSSL_PROTOCOL_ERRORā or āERR_SSL_HANDSHAKE_FAILUREā message. Iāve ensured that the certificate is valid and not expired. Additionally, I checked the HAProxy logs, but there arenāt any clear error messages indicating what might be going wrong. Checked HAProxy SSL Termination (Offloading) Everything to Know Okta documentation guide for reference .
Can someone help me identify the potential misconfiguration or steps I might have missed? Any tips on debugging SSL issues with HAProxy would also be greatly appreciated!
Thank you !