Skip to content

Instantly share code, notes, and snippets.

@pikl-cz
Last active July 2, 2020 07:29
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save pikl-cz/b6eb07d47a369182f0e75013b650f52f to your computer and use it in GitHub Desktop.
Save pikl-cz/b6eb07d47a369182f0e75013b650f52f to your computer and use it in GitHub Desktop.
server {
listen 80;
server_name premonstrati2021.cz www.premonstrati2021.cz;
return 301 https://$server_name$request_uri;
}
server {
listen 443 ssl http2;
listen [::]:443 ssl http2;
root /var/www/html/app/dist;
server_name premonstrati2021.cz www.premonstrati2021.cz;
ssl_dhparam /etc/nginx/dhparam.pem
ssl_certificate "/etc/letsencrypt/live/premonstrati2021.cz/cert.pem";
ssl_certificate_key "/etc/letsencrypt/live/premonstrati2021.cz/privkey.pem";
ssl_verify_client optional;
ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
ssl_ciphers 'ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:ECDHE-ECDSA-AES128-G$
location / {
proxy_pass http://0.0.0.0:3000;
proxy_http_version 1.1;
proxy_ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection 'upgrade';
proxy_set_header Host $host;
proxy_cache_bypass $http_upgrade;
proxy_ssl_server_name on;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment