【发布时间】:2015-01-09 02:49:38
【问题描述】:
我是 openshift 和 nginx 的新手。这是我在 nginx 上使用 php 5.5 创建 DIY 应用程序的第一个实验。 Nginx 服务器运行良好,但是当我添加 php-fpm 配置时:
...
location ~ ^/index.php(/|$) {
root html;
include fastcgi_params;
fastcgi_pass unix:${OPENSHIFT_RUN_DIR}/php-fpm.socket;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME html/$fastcgi_script_name;
fastcgi_param PATH_INFO $fastcgi_script_name;
fastcgi_intercept_errors on;
}
...
在 nginx.conf 中,我的浏览器出现 503 错误,提示服务不可用。我通过许多建议修改了上面的脚本,但仍然没有运气。请问有人吗?谢谢
ps : 我也关注了来自 github 的 https://www.openshift.com/forums/openshift/installing-php-fpm-and-nginx,但仍然没有运气
【问题讨论】:
-
你的日志怎么说?尝试运行“rhc tail
”并粘贴到输出中 -
执行“rhc tail
”后,变量名似乎有错误。 Nginx 无法识别 var $openshift_run_dir。我会解决它。谢谢尼哈维
标签: php nginx configure openshift