在Nginx设置页面上安装Magento 2.0.2不起作用

需要一些帮助安装Magento 2.0.2在nginx 1.9.3与php-fpm目前我使用Magento提供的默认configuration( https://github.com/magento/magento2/blob/develop/nginx.conf.sample )。

发生这个问题的时候是在解包之后访问/设置时,我在“setup / index.php / navigation”上看到了一个403,以及页面试图访问的其他URL。

我已经意识到这背后的问题是,它不是作为一个parameter passing到“index.php文件”,实际上是寻找“index.php /导航”作为一个文件,并试图将其传递给php5-fpm导致security.limit_extensions被触发,导致403。

所以问题变成如何得到正确处理的请求? EX时,由设置index.php呈现的JavaScript请求index.php /导航如何确保它作为parameter passing给index.php而不是试图在“index.php /导航”查找文件,如果索引.php是一个目录。

如我所见,这个问题变得越来越普遍。 看来fastcgi_split_path_info需要定义。 尝试更改nginx.conf.sample / setup位置块(我用##指向解决方案代码):

location /setup { root $MAGE_ROOT; location ~ ^/setup/index.php { ### This fixes the problem: fastcgi_split_path_info ^(.+?\.php)(/.*)$; ################################ fastcgi_pass fastcgi_backend; fastcgi_index index.php; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; include fastcgi_params; } location ~ ^/setup/(?!pub/). { deny all; } location ~ ^/setup/pub/ { add_header X-Frame-Options "SAMEORIGIN"; }}