8.3 KiB
Website Deployment And Versioning
This document defines how Datoviz documentation moves from source changes to the public website. It records the post-RC1 target workflow; it does not make documentation publication a release- candidate blocker by itself.
Current State After RC1
The RC1 website cutover is complete:
datoviz.org/serves the v0.4 release-candidate documentation.datoviz.org/v0.3/preserves the former v0.3 website.- Authored documentation, generated-reference inputs, gallery metadata, and deployment tooling
live in
datoviz/datoviz. - Generated static website files live in the deployment-only
datoviz/datoviz.github.iorepository. - GitHub Pages publishes the root of
datoviz.github.io/maintodatoviz.org.
A push to datoviz/main or datoviz/v0.4-dev does not update the public website. The current
publisher must build and validate the site, commit the generated output to
datoviz.github.io/main, and push that deployment commit.
The local post-RC1 command for the active release-candidate branch is:
just docs-publish yes v0.4-dev no
It requires clean source and website checkouts, builds and validates the WASM scene module, runs a
strict MkDocs build, composes the v0.4 site with the preserved v0.3 archive, checks the staged
deployment, commits it, and pushes datoviz.github.io/main.
Decisions
- Validate documentation automatically on every relevant pull request.
- Keep production publication separate from ordinary source commits.
- Build a release documentation artifact once, then promote those exact bytes.
- Keep
datoviz.github.iodeployment-only; do not author documentation there. - Preserve versioned documentation independently of the production-root selection.
- Require an explicit production approval even when every automated gate is green.
- Treat public media and WASM payloads as first-class deployment artifacts with recorded hashes.
Branch And Version Policy
Through v0.4.0 final, v0.4-dev remains the active release-candidate source branch. After the
controlled final merge:
mainbecomes the single long-lived integration branch.- feature branches remain short-lived and merge through pull requests;
devandv0.4-devare retired or frozen rather than kept as parallel integration branches;- a
release/0.4maintenance branch is created only when v0.4 patch work overlaps with v0.5 development; and - immutable release tags remain the authority for released source and documentation snapshots.
Documentation Channels
The target layout separates continuously changing documentation from promoted releases:
| Channel | Source | Publication policy |
|---|---|---|
/dev/ |
latest validated main commit |
automatic after merge |
/v0.4.0/, /v0.4.1/, ... |
exact release artifact | immutable |
/v0.4/, /v0.5/, ... |
selected release in that series | manually advanced alias |
/v0.3/ |
archived legacy site | preserved |
/ |
explicitly selected release or RC | manual promotion |
The root may point to an RC when the maintainer explicitly chooses that public posture. Updating
/dev/ must never update /, and publishing a versioned snapshot must not implicitly promote it.
Target Pipeline
feature branch or pull request
-> build and validate a preview artifact
-> merge to main
-> publish the validated development channel
-> create an immutable release tag
-> build one release documentation artifact and manifest
-> approve production deployment
-> publish the versioned snapshot and promote the same bytes to the root
Pull Requests
Relevant pull requests must run:
- strict MkDocs build;
- authored/generated documentation drift checks;
- internal-link and stable-route checks;
- gallery reference and media-presence checks;
- WASM module export and deployment checks;
- forbidden-file and maximum-size checks; and
- preview artifact upload.
Pull-request workflows may publish an isolated preview URL, but they must not modify the production website repository or custom domain.
Main
A green merge to main may automatically publish /dev/. Use concurrency control so a newer
deployment supersedes an older queued deployment and two writers cannot race in the website
repository.
Release Tags
The release workflow must build documentation from the exact tag and emit one immutable artifact. The accompanying machine-readable manifest must record at least:
- source repository and full commit hash;
- release version and channel;
- documentation toolchain versions;
- every deployed file path, byte count, and SHA-256 digest;
- the preserved-version inputs; and
- the validation results associated with the artifact.
The production job consumes that artifact. It must not rebuild from the tag after approval, because a second build could change generated output or dependency resolution.
Production Promotion
Production publication uses a protected GitHub environment with a required maintainer approval. The approved job:
- checks out the current deployment repository head;
- verifies the expected predecessor and deployment concurrency lock;
- stages the versioned snapshot without changing older version directories;
- updates the root from the same approved artifact when root promotion was requested;
- verifies the exact staged set and artifact manifest;
- creates an auditable bot-authored deployment commit; and
- pushes
datoviz.github.io/main, allowing GitHub Pages to publish it.
Media And WASM Policy
Canonical screenshots and capture inputs belong in the data repository under its explicit
commit policy. Optimized WebP, MP4, and WASM website outputs are deployment artifacts, not authored
documentation sources.
Before publication:
- every HTML gallery-media reference must resolve within the staged site;
- video files must decode completely and match declared dimensions, duration, frame rate, and size budgets;
- representative posters and animated captures require visual review for release promotion;
- WASM JavaScript imports and exports must match the validated module contract;
- no
.DS_Store, unexpected generated payload, or file over the repository limit may be staged; and - public bytes must match the deployment manifest after GitHub Pages completes.
Missing optional source media may be tolerated while authoring only when generated pages fall back to an existing static asset. Generated HTML must never reference an absent public asset.
Credentials And Repository Protection
Use a GitHub App or narrowly scoped deploy credential that can write only the website repository. Do not use a maintainer's broad personal token for unattended publication.
Protect datoviz.github.io/main so that:
- normal human development does not occur directly on the branch;
- only the reviewed deployment workflow or an explicit emergency-maintainer path can push;
- force pushes and history deletion are disabled; and
- the deployment commit, workflow run, source commit, and artifact manifest remain cross-linked.
Post-RC1 Migration
This infrastructure work is desirable before v0.4.0 final but is not an RC2 feature blocker.
- Keep the current guarded local publisher as the recovery path.
- Add a manually dispatched
Publish documentationworkflow with inputs for source ref, channel, and root promotion. - Move validation and artifact construction into CI while retaining manual production approval.
- Add
/dev/publication aftermainbecomes the integration branch. - Add the deployment manifest and public-byte verification.
- Protect the website repository and replace maintainer credentials with scoped automation.
- Retire the local command as the primary path only after the hosted workflow has completed at least one rehearsed non-production deployment and one approved production deployment.
Completion Criteria
The migration is complete when:
- a pull request produces a validated preview without production write access;
- a maintainer can select an exact source ref and channel from a hosted manual workflow;
- production approval promotes an existing immutable artifact rather than rebuilding it;
- the deployed manifest and public website hashes agree;
/dev/, versioned snapshots, the v0.3 archive, and the production root can be updated independently; and- the guarded local publisher remains documented and tested as an emergency fallback.