Skip to content

Instantly share code, notes, and snippets.

@mping
Created June 27, 2014 21:35
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 mping/dc8c5ba62c631c2cd630 to your computer and use it in GitHub Desktop.
Save mping/dc8c5ba62c631c2cd630 to your computer and use it in GitHub Desktop.
Nginx fastl TLS & SPDY
http {
# usual config stuff...
server {
listen 173.230.151.99:80;
server_name istlsfastyet.com www.istlsfastyet.com;
# redirect to naked domain avoiding http://www -> https://www -> https:// chain.
rewrite ^ https://istlsfastyet.com$request_uri? permanent;
}
ssl_session_cache shared:SSL:10m; # 10MB -> ~40,000 sessions.
ssl_session_timeout 24h; # 24 hours
ssl_buffer_size 1400; # 1400 bytes to fit in one MTU
server {
listen 173.230.151.99:443 ssl spdy;
server_name www.istlsfastyet.com;
rewrite ^ https://istlsfastyet.com$request_uri? permanent;
include includes/ssl.conf;
}
server {
listen 173.230.151.99:443 ssl spdy;
server_name istlsfastyet.com;
# Path for static files
root /home/istlsfastyet/public;
charset utf-8;
include includes/ssl.conf;
include includes/cache.conf;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment