Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save slashbinslashnoname/dde4bc192afb51b1cc818c0fc4a2c191 to your computer and use it in GitHub Desktop.
Save slashbinslashnoname/dde4bc192afb51b1cc818c0fc4a2c191 to your computer and use it in GitHub Desktop.
HTTP vers HTTPS - ledroideenchaine.com
<VirtualHost *:80>
RewriteEngine on
RewriteCond %{SERVER_PORT} !^443$
RewriteRule ^/(.*) https://%{SERVER_NAME}/$1 [L,R]
</VirtualHost>
<VirtualHost *:443>
SSLEngine on
SSLCertificateFile /etc/letsencrypt/live/mondomaine.com/cert.pem
SSLCertificateKeyFile /etc/letsencrypt/live/mondomaine.com/privkey.pem
SSLCACertificateFile /etc/letsencrypt/live/mondomaine.com/fullchain.pem
RewriteEngine on
RewriteCond %{REQUEST_METHOD} ^(TRACE|TRACK)
RewriteRule .* - [F]
</VirtualHost>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment