status: active
timestamp: 2026-06-20
tags: [architecture, git, submodules, deploy, production]
Master pointer as production SHA
Master repo submodule pointers = production SHA state of the family. Bumping a submodule pointer + pushing master = deploying that submodule to production via the matrix workflow.
Master pointer as production SHA
Concept
The master chirag127/oriz repo’s submodule pointers ARE the
production state of the family. The set of SHAs stored in master at
any moment defines exactly what’s deployed to every Cloudflare Pages
project, what’s published to npm for every package, and what version
of the Hono Worker is live at api.oriz.in. Bumping a pointer and
pushing master is the deploy.
How it works
- The matrix workflow at
chirag127/oriz/.github/workflows/deploy.ymlis triggered on push to master’smain - The workflow checks out master with
submodules: recursiveso it sees every site / package / extension at the SHA master points to - It fans out across the matrix:
- Each site →
pnpm wrangler pages deploy distto its Pages project - Each package →
pnpm publish(when version bumped) apps/api/→pnpm wrangler deploytoapi.oriz.in
- Each site →
- Per-repo CI catches breakage at PR time inside each submodule. Master matrix is the production gate.
- Rolling back a single site =
git checkoutan older SHA inside the submodule, then bump the master pointer to that SHA, then push. apps/api/lives INLINE in master (not a submodule) precisely because its deploy must move in lockstep with master pointer bumps.
Why this shape
A single SHA at the top of chirag127/oriz answers “what is in
production right now?” for the whole family. Bisecting a regression
becomes git bisect on master pointers. Pinning production while
exploring on submodules is free — the master pointer just doesn’t
move. Atomic family-wide deploys are possible by bumping multiple
submodules in one master commit.
The same reason argues for keeping apps/api/ inline: the Worker’s
contract is shared by every site, and a Worker deploy that lags
behind a master pointer bump would leave sites calling routes that
don’t exist yet.
Cross-refs
- The submodule mechanics underneath → submodule-pattern.md
- The full repo layout →
- Why the Worker is inline not submoduled → api-umbrella-hono-worker.md
- The host the matrix deploys to → layer-1-static-hosting.md