且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

如何使用OpenShift为裸域添加别名?

更新时间:2023-11-30 17:50:22

这是一个两步过程:

  1. 首先,请确保您有一个DNS提供程序,它提供对裸CNAMES的支持,然后添加一个或多个CNAME条目,这些条目指向OpenShift为应用程序提供的URL(APPNAME-NAMESPACE.rhcloud. com或类似名称.
  2. 接下来,使用rhc alias命令让OpenShift知道,只要通过DNS中配置的任何CNAME接收到请求,您都希望您的应用程序可用. 此步骤也可以通过您的 OpenShift应用管理仪表板在网络上完成.
  1. First, make sure that you have a DNS provider that offers support for naked CNAMES, then and add one or more CNAME entries that point to the URL that OpenShift provided for your application (APPNAME-NAMESPACE.rhcloud.com or similar).
  2. Next, use the rhc alias command to let OpenShift know that you would like your application to be made available whenever a request is received via any of the CNAMEs configured in your DNS. This step can also be completed on the Web via your OpenShift app management dashboard.

例如,如果您想在wordup.com上找到一个名为wordpress的OpenShift应用程序,则rhc alias命令可能如下所示:

For example, if you had an OpenShift application named wordpress that you wanted available at wordup.com, your rhc alias command might look like this:

rhc alias add wordpress wordup.com

我在这里写了一篇帖子来帮助回答这个问题: https://www.openshift.com/blogs/domain-names-and-ssl-in-the-openshift-web-console

I wrote up a post to help answer this question here: https://www.openshift.com/blogs/domain-names-and-ssl-in-the-openshift-web-console