apps/console/README.md and lib/watch/types.ts already documented WATCH_AGENT_TOKEN and RAILYARD_WATCH_LIVE as if stacks/gatus-customers/agent.sh existed. It did not -- the console side (agentChecks/recordResults, the /api/v1/watch/agent/* routes) had nothing on the other end to call it, so Watch could never actually turn on. Adds the real box 1 stack: a Gatus probe engine (docker-compose.yml, config.yaml) plus agent.sh, the bridge that pulls the console's check list, regenerates Gatus's config, reads Gatus's own results, and pushes them back -- stateless by design since the console already dedupes by last_checked_at. Plus agent.env.sample, a systemd unit and install.sh (same shape as tools/reconcile-relay-rago). Verified against real components: a real ghcr.io/twin/gatus:stable container and a scratch server wiring the exact shipped lib/watch/http.ts handlers to a MemoryWatchStore, exercised end to end over two passes against a real https://example.com check -- which caught and fixed two real bugs (Gatus refuses to start with zero endpoints; the generated config's timestamp was forcing a gatus restart on every single pass). Container, volume and image removed afterward; apps/console's existing 167 tests and 3 bundle tests pass unchanged (this item touched no console source file).
5 lines
213 B
YAML
5 lines
213 B
YAML
# GENERATED by agent.sh — do not edit, it is overwritten every pass.
|
|
# Starts empty so `docker compose up` has a valid config before the agent's
|
|
# first pass fills it in from the console's checks.
|
|
endpoints: []
|