1 # You may add here your
5 # statements for each of your virtual hosts to this file
8 # You should look at the following URL's in order to grasp a solid understanding
9 # of Nginx configuration files in order to fully unleash the power of Nginx.
10 # http://wiki.nginx.org/Pitfalls
11 # http://wiki.nginx.org/QuickStart
12 # http://wiki.nginx.org/Configuration
14 # Generally, you will want to move this file somewhere, and start with a clean
15 # file but keep this around for reference. Or just disable in sites-enabled.
17 # Please see /usr/share/doc/nginx-doc/examples/ for more detailed examples.
21 #listen 80; ## listen for ipv4; this line is default and implied
22 #listen [::]:80 default_server ipv6only=on; ## listen for ipv6
24 root /usr/share/nginx/www;
25 index index.html index.htm;
27 # Make site accessible from http://localhost/
28 server_name localhost;
29 return 301 https://$server_name$request_uri;
33 # another virtual host using mix of IP-, name-, and port-based configuration
37 # listen somename:8080;
38 # server_name somename alias another.alias;
40 # index index.html index.htm;
43 # try_files $uri $uri/ =404;
52 server_name localhost;
55 index index.html index.htm;
58 ssl_certificate cert.pem;
59 ssl_certificate_key cert.key;
61 ssl_session_timeout 5m;
63 ssl_prefer_server_ciphers on;
64 ssl_protocols TLSv1 TLSv1.1 TLSv1.2; # not possible to do exclusive
65 ssl_ciphers 'EDH+CAMELLIA:EDH+aRSA:EECDH+aRSA+AESGCM:EECDH+aRSA+SHA256:EECDH:+CAMELLIA128:+AES128:+SSLv3:!aNULL:!eNULL:!LOW:!3DES:!MD5:!EXP:!PSK:!DSS:!RC4:!SEED:!IDEA:!ECDSA:kEDH:CAMELLIA128-SHA:AES128-SHA';
66 add_header Strict-Transport-Security max-age=15768000; # six months
67 # use this only if all subdomains support HTTPS!
68 # add_header Strict-Transport-Security "max-age=15768000; includeSubDomains";
71 try_files $uri $uri/ =404;