2017-04-23 79 views
1

我创建了一个DIY盒,因为我需要运行在PHP 5.6中运行的应用程序,我遵循了这个链接的说明:How to install Nginx on OpenShift如何在OpenShift上设置Nginx?

不过,我收到此错误:“服务暂时无法使用 服务器暂时由于维护停机或容量问题而无法处理您的请求,请稍后再试 Apache/2.2.15(Red Hat)服务器在myapp.rhcloud.com端口80“

我认为错误可能与.openshift/action_hooks/start script:

#!/bin/bash 
# The logic to start up your application should be put in this 
# script. The application will work only if it binds to 
# $OPENSHIFT_DIY_IP:8080 
#nohup $OPENSHIFT_REPO_DIR/diy/testrubyserver.rb $OPENSHIFT_DIY_IP $OPENSHIFT_REPO_DIR/diy |& /usr/bin/logshifter -tag diy & 
# replace the $OPENSHIFT_INTERNAL_IP and $OPENSHIFT_INTERNAL_PORT before starting up the server 
sed -e "s/`echo '$OPENSHIFT_IP:$OPENSHIFT_PORT'`/`echo $OPENSHIFT_DIY_IP:$OPENSHIFT_DIY_PORT`/" $OPENSHIFT_DATA_DIR/conf/nginx.conf.template > $OPENSHIFT_DATA_DIR/conf/nginx.conf 
nohup $OPENSHIFT_DATA_DIR/sbin/nginx > $OPENSHIFT_DIY_LOG_DIR/server.log 2>&1 & 

当我运行RHC尾-a MYAPP

Unable to connect to the server (getaddrinfo: Temporary failure in name 
resolution (https://openshift.redhat.com:443)). Check that you have correctly 
specified your OpenShift server 'https://openshift.redhat.com/broker/rest/api'. 

可能是错了呢?谢谢。

回答

0

OpenShift Online https://status.openshift.com面临停电。这不是今天,我最近还面临另外两天的时间。

enter image description here

我部署this repo on GitHub测试。

curl -I http://myapp-abhishekghosh.rhcloud.com 
HTTP/1.1 200 OK 
Date: Sun, 23 Apr 2017 20:06:16 GMT 
Server: nginx/1.11.1 
Content-Type: text/html 
Content-Length: 41217 
Last-Modified: Sun, 23 Apr 2017 19:49:40 GMT 
Vary: Accept-Encoding 
ETag: "58fd0554-a101" 
Accept-Ranges: bytes 

你可以看到裸露的404页Nginx的 - http://myapp-abhishekghosh.rhcloud.com/broker/rest/api

我无法克隆,因为身份验证服务失败。

最近我发现IBM Bluemix与一些东西更友好,因为OpenShift缺乏对它们的官方支持。你可以看看他们的一个应用程序,他们有Nginx的配置,这对我来说很理智 - https://github.com/IBM-Bluemix/lets-chat-bluemix/blob/master/nginx/nginx.conf。我现在在IBM Bluemix方面的经验确实很少。

其次阿鲁巴云每月1欧元(加增值税)1 GB的VMWare服务器。

我们所有人都在Heroku PaaS后面付出了巨大的努力。我们是否需要在他们的系统背后做出这么多毫无意义的努力?可能会依赖于人。

+0

我收到:“服务暂时不可用”http://myapp.rhcloud.com/broker/rest/api –

+0

是的,Nginx抛出的错误 –