@mandevnull wrote:
Hello, can i use 2 frontends configured with ssl but one frontend in tcp mode and the other in http mode? In the same port (443)
I try this:
frontend http-in
mode http
bind 0.0.0.0:80
bind 0.0.0.0:443 ssl crt /etc/pki/tls/private/cert.pem
option httplog
option dontlognull
option contstatsacl host_host2 hdr(host) -i host2.domain.com use_backend host2_cluster if host_host2
frontend https-in
mode tcp
option tcplog
bind 0.0.0.0:443tcp-request inspect-delay 5s tcp-request content accept if { req.ssl_hello_type 1 } acl host_host1 req.ssl_sni -i host1.domain.com use_backend host1_cluster if host_host1
I get this error in log (not found the server https://host1.domain.com and not found https://host2.domain.com)
Jun 30 10:04:57 localhost haproxy[4570]: 172.21.6.23:36510 [30/Jun/2017:10:04:57.885] http-in~ http-in/ -1/-1/-1/-1/23 503 212 - - SC-- 6/0/0/0/0 0/0 "GET / HTTP/1.1"
thanks in advance!
Posts: 10
Participants: 2