Stanchion docs

Stanchion (formerly cMail): the docs and code keep the old name until the code is renamed.


cmail documentation

cmail is beta software (0.9, before 1.0). Operators should read the deployment and security guides before sending real mail through it. Words like switch, dry run and standby are defined in the Glossary.

Start here

Use cmail

Manage cmail

Deploy and run cmail

  1. Getting started: local setup and Cloudflare storage.
  2. Configuration reference: every setting.
  3. Credentials and permissions: every token, app and secret.
  4. Email authentication: read before changing mail DNS.
  5. Architecture and trust boundaries.
  6. Deployment and verification: the production sequence.
  7. Security checklist and Operations checklist.
  8. Running cmail: upgrade, back up, restore, roll back, monitor, rotate secrets.
  9. Upgrading and keeping your settings.

Sign-in

Microsoft 365 standby

All off by default, each with its own Admin switch. Order and setup: Onboarding an organisation that uses Microsoft 365, with scripts in scripts/onboarding/.

How cmail works

Governance

Contributors and maintainers

Command reference

Run from the repository root:

Command Use
pnpm run setup Create ignored local configuration from committed templates
pnpm dev Start the SvelteKit development server
pnpm dev:worker Start the email Worker with wrangler dev
pnpm db:migrate:verify Apply every migration to a throwaway local D1 and check the schema
pnpm test:mobile Run the Playwright mobile and accessibility suite (see the Developer guide)
pnpm db:migrate:local Apply migrations to isolated local D1 state
pnpm db:migrate:preview Apply migrations to the explicitly isolated preview D1 database
pnpm config:check Verify committed and active Wrangler bindings remain isolated and fail closed
pnpm deploy:email-worker:preview Deploy the isolated, non-sending preview email Worker
pnpm push:keys Generate a VAPID pair for optional browser notifications
pnpm validate Run source, lint, type, test, migration, build, and dependency checks
pnpm release:check Run validation plus the reachable Git-history secret gate

Page metadata

Each page starts with a metadata block between --- lines: title, summary, applies_to (primary, standby or both), audience (any of operator, manager, user), switch (the Admin label that turns the feature on, or none), last_reviewed and related (file names). The docs site reads it for search; GitHub shows it as a table.