Created
June 18, 2018 11:43
-
-
Save mafonso/4cfef9b2026f681bad051409788a31c8 to your computer and use it in GitHub Desktop.
HAProxy examples
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 app1_ssl | |
bind *:443 ssl crt /etc/haproxy/certs.d/example.com.crt crt /etc/haproxy/certs.d/ no-sslv3 | |
option http-server-close | |
option forwardfor | |
reqadd X-Forwarded-Proto:\ https | |
reqadd X-Forwarded-Port:\ 443 | |
# set HTTP Strict Transport Security (HTST) header | |
rspadd Strict-Transport-Security:\ max-age=15768000 | |
# some ACLs and URL rewrites... | |
default_backend backend_app1_ssl | |
backend backend_app1_ssl | |
server mybackendserver 127.0.01:4433 ssl verify none |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment