# http-status-checker

> HTTP status checker used in conjunction with AWS ELB to overcome 1 endpoint check limit

Latest version **1.0.2** (published 2016-03-10) · ISC license · 0 weekly downloads

## Install

```sh
npm install http-status-checker
pnpm add http-status-checker
yarn add http-status-checker
bun add http-status-checker
```

Provides the command `hsc`.

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.2 |
| Published | 2016-03-10 |
| First published | 2016-03-10 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 4 |
| Known vulnerabilities | 0 (+1 in 1 direct dependencies) |
| Install scripts | no |
| Author | Valerio Barrila |
| Maintainers | ninjatux |

## Links

- npm: https://www.npmjs.com/package/http-status-checker
- Homepage: https://github.com/ninjatux/http-status-checker/issues
- Issues: https://github.com/ninjatux/http-status-checker/issues
- npm.io page: https://npm.io/package/http-status-checker

## Dependencies (4)

- [request](https://npm.io/package/request.md) ^2.55.0
- [minimist](https://npm.io/package/minimist.md) ^1.2.0
- [virgilio](https://npm.io/package/virgilio.md) ^0.12.5
- [virgilio-http](https://npm.io/package/virgilio-http.md) ^0.8.1

## Recent versions

- 1.0.2 (latest) — 2016-03-10
- 1.0.1 — 2016-03-10

## README

## HSC

**hsc** (http-status-checker) is a command line utility used to perform multiple HTTP status checks on remote endpoints. It is a perfect fit if you need to host multiple HTTP server on the same EC2 instance behind an Elastic Load Balancer which unfortunately allow status checks on a single HTTP interface.

#### Usage

**hsc** supports accepts options passed as environment variables or as command line arguments. The short list of options is:

* *p* - *env.PORT*, in which port running the *hsc* server (*default 9090*)
* *e* - *env.ENDPOINTS*, comma separated list of endpoints to perform checks against

Install **hsc** globally with `npm i -g http-status-checker`

**hsc** to actually check the status of the endpoints monitored you can perform a *GET* request to `http://your_ip:HSC_PORT/`, if everything looks good **hsc** will simply answer with `HTTP 200 "OK"`, otherwise with an `HTTP 500` containiung in the body a JSON object indicating which endpoint failed the check and which one looks good, eg:

```
{
    http://google.com: "OK",
    http://www.yahoo.com: "OK",
    http://foobarservice.com: "getaddrinfo ENOTFOUND foobarservice.com foobarservice.com:80"
}
```

Usage example:

* `hsc -p 9091 -e http://google.com,http://yahoo.com`

##### Note

Logs are printed in JSON suing [bunyan](https://github.com/trentm/node-bunyan), if you want you can pipe them through the bunyan command line tool to read them better.

---
_Source: https://npm.io/package/http-status-checker · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
