- Make HSTS max-age longer for A+ on qualsys SSL labs
- dhparams 4096 bits vs 2048
filename: "/etc/nginx/conf.d/discourse.conf"
from: /add_header.+/
to: |
- # remember the certificate for 80 days and automatically connect to HTTPS for this domain
- add_header Strict-Transport-Security 'max-age=6912000';
+ add_header Strict-Transport-Security 'max-age=63072000';
cmd:
# Generate strong Diffie-Hellman parameters
- "mkdir -p /shared/ssl/"
- - "[ -e /shared/ssl/dhparams.pem ] || openssl dhparam -out /shared/ssl/dhparams.pem 2048"
+ - "[ -e /shared/ssl/dhparams.pem ] || openssl dhparam -out /shared/ssl/dhparams.pem 4096"
- replace:
filename: "/etc/nginx/conf.d/discourse.conf"
from: /server.+{/