Node.js: Trying to install a script wrapped in forever-monitor as a Windows service using NSSM

I have a net.connect script that I am attempting to install as a service on a Windows XP machine.

The application installs correctly using NSSM prior to my attempt to include forever-monitor.

It also works correctly when launching the forever-monitor script manually.

I have attempted to install forever-monitor local to the app and globally but either way produces the same result.

The service installs and then immediately pauses. It will not start.

Can anyone see what I am doing wrong?

The Forever-Monitor code:

// nstream.js

var forever = require('forever-monitor');

var child = new (forever.Monitor)('nstream.0.0.3.js', {
  silent: true,
});

child.on('exit', function () {
});

child.start();

Issuing the NSSM command from CMD prompt:

c:\avl\src\nssm.exe install "Test" "c:\program files\nodejs\node.exe" "c:\avl\bin\nstream\nstream.js"

The solution, it turns out, is to add the sourceDir option:

// nstream.js

var forever = require('forever-monitor');

var child = new (forever.Monitor)('nstream.0.0.3.js', {
  silent: true,
  sourceDir: 'c:/avl/bin/nstream'
});

child.on('exit', function () {
});

child.start();