Thinkphp 5.0 lnmp rewrite 配置文件

server
{
	listen 80;
	#listen [::]:80;
	server_name domain.com;
	index index.php index.html;
	access_log off;

	set $root /home/wwwroot/domain.com/admin_v1/public;
	location ~ .*\.(gif|jpg|jpeg|bmp|png|ico|txt|js|css)$
	{
		root $root;
	}

	root $root;

	location @rewrite {
		rewrite ^(.*)$ index.php/$1 last;
	}

	location / {
		if ( !-e $request_filename) {
			rewrite ^(.*)$ /index.php/$1 last;
		break;
		}
	}

	location ~ [^/]\.php(/|$)
	{
		fastcgi_pass unix:/tmp/php-cgi.sock;
		fastcgi_index index.php;
		include fastcgi.conf;
		include pathinfo.conf;
	}
}