Skip to content

docs: add verify-replicas.sh example for cross-replica sync verification - #76

Merged
mspinola merged 1 commit into
mainfrom
claude/cotdata-verify-replicas-example
Jul 27, 2026
Merged

mspinola merged 1 commit into
mainfrom
claude/cotdata-verify-replicas-example

Conversation

@mspinola

Copy link
Copy Markdown
Owner

What

Adds docs/examples/mac/verify-replicas.sh — a host-agnostic version of the cross-replica sync check used while standing up the Windows -> {Mac, Linux dash} sync.

Why

The producer feeds two read-only replicas; this confirms a given run actually reached both. It reads a local store and a remote one (over SSH) in one pass, and exits non-zero if either is stale — handy wired to launchd/cron after the producer runs.

How it decides pass/fail

status.json is rewritten on every producer push and carried by the sync, so a replica's status.json mtime date == today means it received today's push. date -r <file> works on both macOS (BSD) and Linux (GNU).

Notes

  • Host, store paths, cotdata-update paths, and SSH key are env-var config with REPLACE_WITH_… markers, matching the style of the other docs/examples/ scripts — no host baked in.
  • Points the "Verifying a sync worked" section at it.

Docs only; no code changes.

🤖 Generated with Claude Code

Templated version of the check used to confirm the producer push reaches every
replica. Reads a local store and a remote one (over SSH) in one pass, keys the
pass/fail on each status.json mtime date (rewritten on every producer push), and
exits non-zero if either replica did not receive today's push. Host, store paths,
cotdata-update paths and SSH key are env-var config with REPLACE_WITH_ markers,
matching the other docs/examples/ scripts; no host is baked in.

Point the "Verifying a sync worked" section at it, and note the status.json
mtime signal and wiring it to launchd/cron after the producer run.

Docs only; no code changes.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@mspinola
mspinola merged commit 931edf8 into main Jul 27, 2026
5 checks passed
@mspinola
mspinola deleted the claude/cotdata-verify-replicas-example branch July 27, 2026 23:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant