Created
October 16, 2019 21:18
-
-
Save Ne00n/b52e112afa5d587178920e0164691083 to your computer and use it in GitHub Desktop.
HAProxy SNI TLS + HTTP
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
frontend https | |
bind :443 | |
mode tcp | |
acl tls req.ssl_hello_type 1 | |
tcp-request inspect-delay 5s | |
tcp-request content accept if tls | |
#Define hosts | |
acl host_nano.test.com_https req.ssl_sni -i nano.test.com | |
use_backend nano.test.com_https if host_nano.test.com_https | |
backend nano.test.com_https | |
server nano.test.com 10.10.1.20:443 | |
mode tcp | |
frontend http | |
bind :80 | |
mode http | |
#Define hosts | |
acl host_nano.test.com hdr(host) -i nano.test.com | |
use_backend nano.test.com if host_nano.test.com | |
backend nano.test.com | |
server nano.test.com 10.10.1.20:80 | |
mode http |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment