Skip to content

Node port of mongroup(1) - group process monitoring backed by mon(1) instances

Notifications You must be signed in to change notification settings

tj/node-mongroup

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

node-mongroup

A nodejs port of mongroup, a group-based process monitor backed by mon.

Installation

$ npm install -g mongroup

mongroup(1)

The mongroup executable is also aliased as mg.


  Usage: mongroup [options]

  Options:

    -h, --help           output usage information
    -V, --version        output the version number
    -c, --config <path>  load configuration [./mongroup.conf]
    -j, --json           output json

  commands:

    status           output process status
    stop [names]     stop all or specified processes
    start [names]    start all or specified processes
    restart [names]  restart all or specified processes

Configuration

Example configuration.

# settings

logs = /tmp/logs
pids = /tmp/pids

# web app

web-1 = node server 9001
web-2 = node server 9002
web-3 = node server 9003
web-4 = node server 9004

JSON output

$ mg status --json

{
  "web-1": {
    "state": "alive",
    "pid": 3562,
    "uptime": 1433
  },
  "web-2": {
    "state": "alive",
    "pid": 3565,
    "uptime": 1433
  },
  "web-3": {
    "state": "alive",
    "pid": 3567,
    "uptime": 1433
  },
  "web-4": {
    "state": "alive",
    "pid": 3569,
    "uptime": 1433
  }
}

License

MIT

About

Node port of mongroup(1) - group process monitoring backed by mon(1) instances

Resources

Stars

Watchers

Forks

Packages

No packages published