Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- 2016/12/06 17:12:37 [alert] 1349#1349: *12 open socket #12 left in connection 2
- 2016/12/06 17:12:37 [alert] 1349#1349: aborting
- 2016/12/06 17:46:40 [alert] 2655#2655: *12 open socket #13 left in connection 3
- 2016/12/06 17:46:40 [alert] 2655#2655: aborting
- server {
- #listen 80;
- index index.html index.php;
- ## Begin - Server Info
- root /var/www/serwer;
- server_name localhost;
- ## End - Server Info
- ## Begin - Index
- # for subfolders, simply adjust:
- # `location /subfolder {`
- # and the rewrite to use `/subfolder/index.php`
- location / {
- try_files $uri $uri/ /index.html /index.php;
- }
- ## End - Index
- ## Begin - PHP
- location ~ .php$ {
- # Choose either a socket or TCP/IP address
- #fastcgi_pass unix:/var/run/php/php7.0-fpm.sock;
- fastcgi_pass 127.0.0.1:9000;
- fastcgi_split_path_info ^(.+.php)(/.+)$;
- fastcgi_index index.php;
- include fastcgi_params;
- fastcgi_param SCRIPT_FILENAME $document_root/$fastcgi_script_name;
- }
- ## End - PHP
- ## Begin - Security
- # deny all direct access for these folders
- location ~* /(.git|cache|bin|logs|backups|tests)/.*$ { return 403; }
- # deny running scripts inside core system folders
- location ~* /(system|vendor)/.*.(txt|xml|md|html|yaml|php|pl|py|cgi|twig|sh|bat)$ { return 403; }
- # deny running scripts inside user folder
- location ~* /user/.*.(txt|md|yaml|php|pl|py|cgi|twig|sh|bat)$ { return 403; }
- # deny access to specific files in the root folder
- location ~ /(LICENSE.txt|composer.lock|composer.json|nginx.conf|web.config|htaccess.txt|.htaccess) { return 403; }
- ## End - Security
- location /phpmyadmin {
- root /usr/share/;
- index index.php index.html index.htm;
- location ~ ^/phpmyadmin/(.+.php)$ {
- try_files $uri =404;
- root /usr/share/;
- fastcgi_pass 127.0.0.1:9000;
- fastcgi_index index.php;
- fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
- include /etc/nginx/fastcgi_params;
- }
- location ~* ^/phpmyadmin/(.+.(jpg|jpeg|gif|css|png|js|ico|html|xml|txt))$ {
- root /usr/share/;
- }
- }
- location /phpMyAdmin {
- rewrite ^/* /phpmyadmin last;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement