简体   繁体   English

负载均衡Node.js应用

[英]Load balancing nodejs app

I am currently deploying an instance of nodejs app to server, for loadbalancing I am using phusion passenger, which I find really handy. 我目前正在将nodejs应用程序实例部署到服务器,为了实现负载平衡,我使用的是phusion passenger,我觉得这非常方便。 Now I am wondering do I also need an nginx server in front of phusion passenger app, if I deploy only one app in my virtual machine. 现在,我想知道如果在虚拟机中仅部署一个应用程序,我是否还需要在phusion passenger应用程序前面安装一台nginx服务器。 The reason I was confused because in almost all the tutorial it was suggested to use nginx with nodejs. 我之所以感到困惑,是因为在几乎所有教程中都建议将Nginx与nodejs一起使用。 However I am not sure what is the need of having nginx as I am using phusion passenger for load balancing and static file serving. 但是,我不确定使用nhuxx的需求是什么,因为我正在使用phusion passenger进行负载平衡和静态文件服务。

Phusion Passenger runs inside Nginx, so if you're using Phusion Passenger you're already using Nginx. Phusion Passenger Nginx中运行,因此,如果您使用的是Phusion Passenger,那么您已经在使用Nginx。 There's no need to put another Nginx before it. 无需在其之前放置另一个Nginx。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM