Advertisement
Guest User

config nginx

a guest
Feb 25th, 2018
96
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.48 KB | None | 0 0
  1. server {
  2. listen 80 ;
  3. listen 443 ssl http2;
  4. listen [::]:443 ssl http2;
  5. server_name elibrary.rajadev.com www.elibrary.rajadev.com;
  6. ssl_session_timeout 1d;
  7. ssl_session_cache shared:SSL:50m;
  8. ssl_session_tickets off;
  9. ssl_protocols TLSv1.2;
  10. ssl_ciphers EECDH+AESGCM:EECDH+AES;
  11. ssl_ecdh_curve secp384r1;
  12. ssl_prefer_server_ciphers on;
  13. ssl_certificate /usr/share/nginx/apibnivision/cert.pem;
  14. ssl_certificate_key /usr/share/nginx/apibnivision/key.pem;
  15. ssl_stapling on;
  16. ssl_stapling_verify on;
  17. add_header Strict-Transport-Security "max-age=15768000; includeSubdomains; preload";
  18. add_header X-Frame-Options DENY;
  19. add_header X-Content-Type-Options nosniff;
  20. # Tell Nginx and Passenger where your app's 'public' directory is
  21. root /usr/share/nginx/html;
  22. index index.php index.html index.htm;
  23. location / {
  24. try_files $uri $uri/ =404;
  25. }
  26. error_page 404 /404.html;
  27. error_page 500 502 503 504 /50x.html;
  28. location = /50x.html {
  29. root /usr/share/nginx/html;
  30. }
  31. location ~ \.php$ {
  32. try_files $uri =404;
  33. fastcgi_index index.php;
  34. fastcgi_pass unix:/var/run/php-fpm/php-fpm.sock;
  35. fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
  36. include fastcgi_params;
  37. }
  38. location ~ /\.ht {
  39. deny all;
  40. }
  41. error_log /var/log/nginx/sistemperpus.log;
  42. access_log /var/log/nginx/sistemperpus.log;
  43. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement