Skip to content

Deployment

pH7x Systems edited this page Jul 18, 2026 · 6 revisions

Deployment

cms export --target NAME produces everything a host needs; the output is plain static files plus target-specific extras.

Targets

swa — Azure Static Web Apps

Adds staticwebapp.config.json: security headers (nosniff, frame options, referrer policy, permissions policy), cache rules (immutable-ish for /assets/*, no-cache for pages), and a proper 404 rewrite. Free and Standard tiers take the same artifact.

nginx

Adds an nginx server block with the same security headers and a container-ready layout.

generic (default)

Plain static files for any host.

The demo pipeline (reference implementation)

The live demo (https://stillsite.ph7x.com) deploys from GitHub Actions on every push to main:

  1. Install the packages, cms seed a fresh SQLite database (deterministic fixtures).
  2. cms validate — the gate; errors fail the deploy.
  3. cms export --target swa.
  4. python -m cms_admin.demo_export — captures the read-only admin snapshot into _site/admin/.
  5. Upload _site/ to Azure Static Web Apps.

The same pattern works with real content: point the workflow at your storage URL instead of seeding.

Quality gates in CI

The repository runs nine required checks on every PR: ruff (lint + format), mypy strict, pytest on Python 3.12 and 3.13, PostgreSQL storage conformance (service container), the example build, offline docs link checking, secret scanning over the whole git history, W3C markup validation (html5validator/vnu) and an axe-core accessibility gate (WCAG 2.2 AA, fails on serious/critical) over the built demo pages.

Clone this wiki locally