node package manager


Single thread, multiple host node application server


run multiple servers in one node.js process, restarting individual servers when their code files change on disk

servlet uses [] to monitor server module source files and its own configuration file. Modules are reloaded to realize changes immediately.

As root:

> servlet config.conf 80 wwwdata:wwwdata

As an unpriviliged user:

> servlet config.conf 8080

  { "host": "", "file": "./project1/index.js" },
  { "host": "", "file": "../funstuff/server.js" }
var app = require('http').createServer(function(req,res){res.end(req.url)})
exports.start = function( options ) {
  // start listening on the port assigned to the servlet
  app.listen( options.port );
exports.stop = function() {
  // clean up

On Ubuntu systems upstart can be used to launch servlet at boot time and keep it running. Check out node-servlet.conf for an upstart example config file.