Gated release with append-only migrations

The idea

One script builds the committed head, migrates in a throwaway container, swaps the image, checks health gates and rolls back on failure. Released migrations never change.

The problem
A bad build or schema change could reach production and be hard to undo.
Why it matters
Every release runs the same gates, docs-only changes skip the build, and schema changes only add.
Where it stands
In production as of

A step-by-step replay of this idea is not published yet. The library adds one when a recorded run shows it.

  • Background leader lock

    Only the process that holds a Postgres advisory lock runs background work. Other processes serve requests as warm standbys.

  • Changelog from commit trailers

    The public changelog and its RSS feed are built from one-line commit trailers. A build fails when a commit has had no note for 7 days.

  • Test isolation checks

    Each database test file gets its own database, cloned from a template keyed by schema hash. A socket to anything but loopback fails the test, CLIs are fakes, and deploy gates run in a sandbox.

Turn the numbers into shipped work.

Crewshal runs these choices for you: a persistent AI worker with memory and rules, on your Claude and Codex subscriptions.