【问题标题】:Handling fastcgi_param with HHVM fastcgi in Nginx在 Nginx 中使用 HHVM fastcgi 处理 fastcgi_param
【发布时间】:2014-01-29 18:25:18
【问题描述】:

通过 fastcgi 进入 Nginx 的 HHVM 不支持 fastcgi_param 是否正确?如果是这样,如何解决?

喜欢:

location ~ .php$ { ## Execute PHP scripts
    if (!-e $request_filename) { rewrite / /index.php last; }
    expires        off;
    fastcgi_pass   127.0.0.1:9999; <- my hhvm is set to port 9999 io 9000
    fastcgi_param  PHP_VALUE "error_log=/var/report/PHP.error.log";
    fastcgi_param  SCRIPT_FILENAME  $document_root$fastcgi_script_name;
    fastcgi_param  MAGE_RUN_CODE admin;
    fastcgi_param  MAGE_RUN_TYPE store;
    include        fastcgi_params;
}

【问题讨论】:

标签: nginx fastcgi hhvm


【解决方案1】:

是的,我可以确认带有server.type = fastcgi 的 hhvm 服务器确实实现了 fastcgi 参数并且可以使用 fastcgi_param nginx 指令。

您的 nginx 位置块对我来说似乎有点不完整。我建议至少执行官方 HHVM 文档https://github.com/facebook/hhvm/wiki/FastCGI#making-it-work-with-nginx 中的所有指令。

我相信您至少需要在您的 php 位置块处理程序的范围内拥有这些指令。

  • root
  • fastcgi_index

另外,请确保您的 hhvm 配置 (php.ini) 已针对 fastcgi 正确设置。

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2015-02-04
    • 1970-01-01
    • 1970-01-01
    • 2015-06-10
    • 1970-01-01
    • 2012-09-01
    • 1970-01-01
    • 2023-04-05
    相关资源
    最近更新 更多