salt/states/roles/maintain/laradev/nginx.conf

37 lines
892 B
Nginx Configuration File

server {
listen 8080;
server_name {{server}}.actcur.com;
root /sites/{{server}}/prod/public;
index index.html index.htm index.php;
charset utf-8;
rewrite_log on;
location @laravel {
rewrite ^(/[^/]+/[^/]+)/(.*)$ $1/index.php?$2 last;
}
location / {
try_files $uri $uri/ @laravel;
}
location = /favicon.ico { access_log off; log_not_found off; }
location = /robots.txt { access_log off; log_not_found off; }
error_page 404 /index.php;
location ~ \.php$ {
fastcgi_pass unix:/run/php-fpm/php-fpm.sock;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $realpath_root$fastcgi_script_name;
include fastcgi_params;
}
location ~ /\.(?!well-known).* {
deny all;
}
error_log /var/log/nginx/ra_error.log notice;
access_log /var/log/nginx/ra_access.log;
}