@ganeshak11/healthcheck
v1.1.0
Published
A rapid diagnostic CLI for DevOps
Readme
🩺 @ganeshak11/healthcheck
A production-grade, miniature SRE observability CLI tool. It deeply inspects domains and provides a comprehensive diagnostic report covering DNS, SSL, HTTP/2, and Security Posture.
It goes far beyond a simple ping by tracking HTTP redirects, detecting ALPN negotiated protocols, evaluating strict security headers, and calculating an overall Health Score. It is built to be modular, supporting multiple domains and CI/CD pipelines natively.
🚀 Quick Start
Run it instantly against any domain using npx:
npx @ganeshak11/healthcheck google.com✨ Features
- DNS Diagnostics: Concurrently resolves IPv4 (
A) and IPv6 (AAAA) records. - Deep SSL Inspection: Evaluates the SSL Certificate issuer, exact expiry dates, Cipher Suite, and negotiated TLS Version.
- ALPN HTTP/2 Detection: Injects
ALPNProtocolsinto the TLS socket to natively determine if the server supports HTTP/2 binary framing. - Actionable Security Posture: Checks for 6 strict security headers (e.g.
Content-Security-Policy,HSTS) and provides clear explanations for why they matter. - Smart Scoring Engine: Calculates an Overall Health Score (out of 10) and provides a list of actionable recommendations.
- CI/CD Ready:
- Supports
--jsonflag to output raw structured data. - Returns standard exit codes (
0for Healthy,1for Security warnings,2for SSL warnings,3for HTTP errors,4for DNS failures).
- Supports
- Multi-Domain Support: Pass an array of domains to generate a sleek comparative score table.
💻 Usage
Single Domain Inspection
npx @ganeshak11/healthcheck yourdomain.comMulti-Domain Comparison
npx @ganeshak11/healthcheck google.com github.com example.comCI/CD JSON Output
npx @ganeshak11/healthcheck yourdomain.com --json🛠️ Built With
- Node.js Native Modules (
dns,tls,https,http) - TypeScript
- Boxen & Chalk for the UI
📦 Local Development
- Clone the repository
- Install dependencies:
npm install - Compile the TypeScript:
npm run build - Run the CLI:
node dist/index.js google.com
Built as part of the Fortis-Tools DevOps toolkit.
