appherder

3.0.0 • Public • Published

appherder

CLI to start & watch a bunch of local app servers:

  • Scans for open ports and passes them to the app servers through the PORT environment variable
  • Will restart a server if the process dies
  • Opens a HTTP endpoint which returns server to port mappings for service discovery
  • Each app's output goes straight to stdout/stderr, therefore each app is responsible for identifying itself in its loglines

Usage

The directory where you run appherder must have a configuration file called appherd.json:

{
  "port": 7000,
  "apps": {
    "server1": {
      "command": "node",
      "args": ["server1/index.js"]
    },
    "server2": {
      "command": "node",
      "args": ["server2/index.js"]
    }
  }
}

Once that's set up, run appherder.

Open http://localhost:7000. Given port 7001 and 7002 are free, you should get the following JSON response with the above configuration:

{
  "server1": 7001,
  "server2": 7002
}

Readme

Keywords

none

Package Sidebar

Install

npm i appherder

Weekly Downloads

5

Version

3.0.0

License

MIT

Last publish

Collaborators

  • khoomeister