Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- server {
- # Replace this port with the right one for your requirements
- listen 80; #could also be 1.2.3.4:80
- # Multiple hostnames separated by spaces. Replace these as well.
- server_name admin.black.local; # Alternately: _
- root /home/cawa/www/secretcloset_black/admin-black/web;
- #error_page 404 errors/404.html;
- # error_log /home/cawa/www/secretcloset_black/admin-black/nginx_dev.log error;
- index app_dev.php;
- # unless the request is for a valid file (image, js, css, etc.), send to bootstrap
- if (!-e $request_filename)
- {
- rewrite ^/(.*)$ /app_dev.php?/$1 last;
- break;
- }
- location / {
- try_files $uri $uri/ /app_dev.php?$query_string;
- }
- location ~* \.php$ {
- try_files $uri = 404;
- fastcgi_split_path_info ^(.+\.php)(/.+)$;
- fastcgi_pass unix:/var/run/php/php7.0-fpm.sock; #unix:/var/run/php5-fpm.sock; # /var/run/php/php7.0-fpm.sock
- fastcgi_index app_dev.php;
- fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
- include fastcgi_params;
- }
- location ~* ^(.+)@2x.(jpg|jpeg|gif|png)$ {
- try_files $uri $1.$2 =404;
- }
- #include common/php;
- location ~ /\.ht {
- deny all;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement