Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

http-status-checker

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

http-status-checker

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

  • 1.0.2
  • latest
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

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, if you want you can pipe them through the bunyan command line tool to read them better.

FAQs

Package last updated on 10 Mar 2016

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc