src/bin/fork.js

changeset 9
3d4d0e0dd4de
parent 5
ee8de27ff264
equal deleted inserted replaced
0:3d02ea3a3c29 1:4d37be38feba
35 | Execute: To start this application, launch it with the | 35 | Execute: To start this application, launch it with the |
36 | script named fork.js: $ ./fork.js | 36 | script named fork.js: $ ./fork.js |
37 | | 37 | |
38 | Support: http://list.europalab.com/mailman/mdnsgs/ | 38 | Support: http://list.europalab.com/mailman/mdnsgs/ |
39 | | 39 | |
40 | Test: dig @nodeapp.host.tld A realhost.local |
41 | |
40 ***********************************************************/ 42 ***********************************************************/
41 43
42 // import module dependencies 44 // import module dependencies
43 var forkserv = require('forever-monitor'); 45 var forkserv = require('forever-monitor');
44 46
45 47
46 // configure a child process to daemonize 48 // configure a child process to daemonize
47 var childproc = new (forkserv.Monitor)('app.js', { 49 var childproc = new (forkserv.Monitor)('src/lib/app.js', {
48 max: 4, 50 max: 4,
49 silent: true, 51 silent: true,
50 pidFile: '/tmp/mdnsgw.pid', 52 pidFile: '/tmp/mdnsgw.pid',
51 logFile: '/tmp/mdnsgw.log', 53 logFile: '/tmp/mdnsgw.log',
52 outFile: '/tmp/mdnsgw.out', 54 outFile: '/tmp/mdnsgw.out',

mercurial