Skip to main content

相关

** Laradock环境下的fastadmin伪静态参考 **
server {

listen 80;
listen [::]:80;

server_name metro.loc;
root /var/www/metro.loc/public;
index index.php index.html index.htm;
location / {
try_files $uri $uri/ /index.php$is_args$args;
index index.php index.html index.htm;
if (!-e $request_filename) {
rewrite ^/(.*)$ /index.php/$1 last;
}
}

location ~ ^(.+\.php)(.*)$ {
fastcgi_pass php-upstream;
fastcgi_split_path_info ^(.+\.php)(.*)$;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_param PATH_INFO $fastcgi_path_info;
include fastcgi_params;
}

location ~ /\.ht {
deny all;
}

location /.well-known/acme-challenge/ {
root /var/www/letsencrypt/;
log_not_found off;
}
}