Nginx 分发 Apache
2017-10-13 本文已影响0人
邱杉的博客
<Directory />
# 不使用目录下的 .htaccess 文件
AllowOverride none
Allow from all
Options +FollowSymLinks
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^ index.php [L]
</Directory>
location / { #通用匹配,最后执行
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header Host $host;
proxy_pass http://127.0.0.1:8098;
#try_files $uri $uri/ /index.php;
#try_files $uri $uri/ /index.php?$query_string;
#return 200 $request_uri;
}