Getting started with Doctor

Install Doctor, check it is watching, and prove it heals. Written for anyone.

Getting started with Doctor

Install Doctor, check it is watching, and prove it heals. Written for anyone.

Related:


#1. It is installed with the Apiary

The Apiary installer sets Doctor up automatically, including registering it with your operating system so it survives crashes and reboots.

macOS or Linux

curl -fsSL https://get.theapiary.sh | sh

Windows (PowerShell)

irm https://get.theapiary.sh/install.ps1 | iex

Prefer to be your own on-call? Add --no-doctor to skip it.

#2. Install or update it on its own

You can also install or update Doctor by itself, then register the OS service:

npm install -g @legioncodeinc/doctor
doctor install-service

Doctor registers per user, so there is no sudo prompt on macOS or Linux and no admin prompt on Windows.

#3. Check that it is watching

doctor status

This shows daemon health, service state, versions, when it last healed something, and your opt-out flags.

#4. Prove it heals

Kill a daemon on purpose, wait about half a minute, and check again. It comes back on its own, with a fresh note of the last repair.

pkill -f honeycomb
sleep 30
doctor status

#5. See the status page

Doctor serves a human-readable status page on your machine at http://127.0.0.1:3852, which works even when everything else is down. The same data is available as a machine-readable feed at /status.json.

#Turning it off

doctor uninstall-service

This removes the OS registration cleanly. The rest of the stack keeps running; you are just back to being your own on-call.

#What next