Socket
Book a DemoInstallSign in
Socket

pingme

Package Overview
Dependencies
Maintainers
2
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

pingme

Super simple HTTP server that can be easily pinged so that Nagios et al can know your stuff's healthy.

latest
Source
npmnpm
Version
1.0.1
Version published
Maintainers
2
Created
Source

pingme

Super simple HTTP server that can be easily pinged so that Nagios et al can know your stuff's healthy.

USAGE

var pm = require('pingme');
pm({
  status: function(cb) {
    // cb(new Error('oh noes!')); if not ok
    cb(null, {
      pid: process.pid,
      whateverRandom: dataYouWantToShow
    })
  },
  ping: function(cb) {
    cb(null); // cb(new Error('oh noes!')) if not ok
  },
  // pass in ssl: { key, cert } to use https instead
  // pass in `server: someServer` to hijack its request handler
  // but be warned that this takes over the /ping and /status urls
}).listen(1337);

Keywords

ping

FAQs

Package last updated on 15 Jul 2015

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