On Thursday, November 14, 2013 8:22:16 PM UTC+4, Eric Mill wrote:
>
> I'm totally fine being told that the Unicorn model is the wrong way to 
> think of things in Node. But what are the best practices
>

There is no such thing called "best practice". You can ask what other 
people do, but the best way to do something simply doesn't exist. 
 

> for deploying a Node app where I'd like to be able to scale the number of 
> processes up and down easily on a box? The model I'm used to is putting 
> nginx in front, having it proxy to a Unix socket, and then having Unicorn 
> watch the same Unix socket.
>
> I'm aware of node-http-proxy<https://github.com/nodejitsu/node-http-proxy> - 
> should I run one of these with forever<https://github.com/nodejitsu/forever> 
> -- 
> and then also manage my express processes with forever? How should I be 
> conceiving of the problem?
>

I'm using nginx for reverse proxy and pm2 for a supervisor. Nginx serves 
static files faster (node-http-proxy is good, but it more suited for other 
uses), and pm2 works better for me for a number of reasons.

By the way yes, you would probably want to manage your processes with a 
some kind of supervisor. It's quite usual to node processes to crash, and 
it'll be nice to have something to restart them. 
 

-- 
-- 
Job Board: http://jobs.nodejs.org/
Posting guidelines: 
https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
You received this message because you are subscribed to the Google
Groups "nodejs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/nodejs?hl=en?hl=en

--- 
You received this message because you are subscribed to the Google Groups 
"nodejs" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to