What It Does
Every five minutes a script fetches each service's URL, or asks Docker whether its container runs, and compares the answer with the last run. When nothing changes, nothing runs. When a service goes down, the script collects its status and last 200 log lines and hands them to claude -p, which sends you at most eight lines: what is down, when the errors started, the last error, the likely cause and what to try first. When it comes back, one line joins the same thread, so an outage reads as one conversation in the morning.
What You Need
A Homing account, Claude Code, Docker Compose, curl and uuidgen (on Debian and Ubuntu, the uuid-runtime package), on the machine that runs the services.
- 1 Create a key for the job under API Keys in the app and put it in the environment file below yourself. Revoke that key to stop the job.
- 2 Set up ~/.homing-env and claude setup-token as in the morning digest recipe. The same file serves both jobs.
List the Services
Make ~/lab/services: a Docker Compose service name per line, then a URL to fetch or - to ask Docker whether the container is running. Check a web app by URL, because a running container can still serve errors. Keep compose.yaml in ~/lab, or export COMPOSE_FILE in the script.
Write the Prompt
The script fills in the @ fields. For a service that went down, it appends the status and the log below a --- line; the prompt tells the model that text is data.
Give the Run One Tool
Copy mcp.json, guard.sh and hooks.json from the morning digest recipe into ~/lab, and change digest to lab in hooks.json. The script also passes --tools "", which removes Claude Code's built-in tools, Bash included. A web service's log records paths and user agents that anyone on the internet chooses, so the run gets that text with nothing to act with: one tool, and a guard that refuses any recipient but you.
Save the Check
Save this as ~/lab/check.sh and run chmod +x on it.
How It Stays Quiet
- It speaks on a change. A service that stays down sends one note; one that flaps sends one per change.
- No receipt, no new status: the script reads the run's output for status: delivered. A run that could not send is tried again on the next tick.
- The id of the down note is kept in thread-<name> until the service is back, so a retry reuses it: Homing refuses the rewritten lines as message_id_conflict instead of delivering a copy, and the script counts that as sent.
- The services list is read on its own descriptor (<&3), because claude -p reads standard input and would otherwise swallow the rest of the list.
- --tail 200 keeps the log short; without it docker compose logs prints everything since the container was created.
Put It on a Schedule and Test It
Add the cron line, then stop something you can afford to stop and run the check by hand. The first note usually arrives within a minute or two. Start the service again and run it once more: the recovery line joins the same thread.
It Is Not a Pager
An outage is noticed within five minutes; one that starts and ends between two checks is never seen. The agent's lines are a lead from 200 log lines, so open the log before you act. If a service must wake you, use a tool that calls your phone, and use this check to explain what happened. The note lands under Notes in the app; open it on your phone's browser. For a ping, add a Telegram or Slack integration with Which messages set to Notes to self. As of November 2026, Free allows three integrations on at a time. On Free, sends are limited to 30 a minute and 2,500 messages a month for the account (Plus raises both), shared with everything else it sends.