Advertisement
Guest User

Untitled

a guest
Dec 6th, 2016
73
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.39 KB | None | 0 0
  1. 2016/12/06 17:12:37 [alert] 1349#1349: *12 open socket #12 left in connection 2
  2. 2016/12/06 17:12:37 [alert] 1349#1349: aborting
  3. 2016/12/06 17:46:40 [alert] 2655#2655: *12 open socket #13 left in connection 3
  4. 2016/12/06 17:46:40 [alert] 2655#2655: aborting
  5.  
  6. server {
  7. #listen 80;
  8. index index.html index.php;
  9.  
  10. ## Begin - Server Info
  11. root /var/www/serwer;
  12. server_name localhost;
  13. ## End - Server Info
  14.  
  15. ## Begin - Index
  16. # for subfolders, simply adjust:
  17. # `location /subfolder {`
  18. # and the rewrite to use `/subfolder/index.php`
  19. location / {
  20. try_files $uri $uri/ /index.html /index.php;
  21. }
  22. ## End - Index
  23.  
  24. ## Begin - PHP
  25. location ~ .php$ {
  26. # Choose either a socket or TCP/IP address
  27. #fastcgi_pass unix:/var/run/php/php7.0-fpm.sock;
  28. fastcgi_pass 127.0.0.1:9000;
  29.  
  30. fastcgi_split_path_info ^(.+.php)(/.+)$;
  31. fastcgi_index index.php;
  32. include fastcgi_params;
  33. fastcgi_param SCRIPT_FILENAME $document_root/$fastcgi_script_name;
  34. }
  35. ## End - PHP
  36.  
  37. ## Begin - Security
  38. # deny all direct access for these folders
  39. location ~* /(.git|cache|bin|logs|backups|tests)/.*$ { return 403; }
  40. # deny running scripts inside core system folders
  41. location ~* /(system|vendor)/.*.(txt|xml|md|html|yaml|php|pl|py|cgi|twig|sh|bat)$ { return 403; }
  42. # deny running scripts inside user folder
  43. location ~* /user/.*.(txt|md|yaml|php|pl|py|cgi|twig|sh|bat)$ { return 403; }
  44. # deny access to specific files in the root folder
  45. location ~ /(LICENSE.txt|composer.lock|composer.json|nginx.conf|web.config|htaccess.txt|.htaccess) { return 403; }
  46. ## End - Security
  47.  
  48. location /phpmyadmin {
  49. root /usr/share/;
  50. index index.php index.html index.htm;
  51. location ~ ^/phpmyadmin/(.+.php)$ {
  52. try_files $uri =404;
  53. root /usr/share/;
  54. fastcgi_pass 127.0.0.1:9000;
  55. fastcgi_index index.php;
  56. fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
  57. include /etc/nginx/fastcgi_params;
  58. }
  59. location ~* ^/phpmyadmin/(.+.(jpg|jpeg|gif|css|png|js|ico|html|xml|txt))$ {
  60. root /usr/share/;
  61. }
  62. }
  63. location /phpMyAdmin {
  64. rewrite ^/* /phpmyadmin last;
  65. }
  66. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement