在Webfaction控制面板中,单击Domains/Websites -> Applications -> Add new application。在App category下拉列表中,选择Custom,然后在App type中选择Custom app (listening on port)。然后您应该看到以下文本(强调我的):
This installer assigns an unprivileged port on which custom software
can listen.
This creates the ~/webapps// directory for your convenience;
however, the custom application is not required to reside there.
After the installer has finished, configure your custom software to
listen to the port number specified in the "port" field. If the
application is configured in a website record, the front-end server
proxies incoming requests at the specified URL to the assigned port.
Note: Custom applications are intended for handling HTTP traffic. If
you need direct access to the port, please open a support ticket to
request access to the assigned port.
在Webfaction控制面板中,单击
Domains/Websites -> Applications -> Add new application
。在App category
下拉列表中,选择Custom
,然后在App type
中选择Custom app (listening on port)
。然后您应该看到以下文本(强调我的):因此,您需要决定您的即时消息应用程序是通过HTTP进行通信还是通过直接访问端口进行通信,并相应地采取行动。为了简单起见,我假设您希望使用HTTP,但选择权取决于您。不过,一定要先通读custom applications documentation。这将是一个真正的自定义应用程序,因此您将需要编写逻辑来检查服务器是否仍在运行,如果需要,定期重新启动它,应用
cron
作业,随着负载的增加而增加运行的服务器实例的数量,等等祝你好运!在
在文档上http://docs.webfaction.com/software/custom.html 如果你想要一个特定的端口,你需要开一张票:https://community.webfaction.com/questions/14771/open-custom-application-on-a-specific-port-to-serve-mongodb-httpd-for-simple-rest-interface
顺便说一句,webfiction有一个QA社区页面更适合这类问题https://community.webfaction.com/
相关问题 更多 >
编程相关推荐