Deployment Product Flow¶
Status: active Last updated: 2026-05-29
This document defines the developer-facing deployment flow built on immutable release bundles for local agent-skills instances.
This is pre-release documentation. It describes how the flow should work and how it is verified, but it does not mean a public release should be executed yet.
1. Goal¶
Provide a deployment experience that is:
- Bundle-based and traceable
- Preview-friendly for pull requests
- Promotable across
preview -> dev -> staging -> prod - Rollback-capable without ad hoc file surgery
This flow is intentionally local-instance compatible. Each deployed agent-skills instance can build, verify, promote, and rollback its own bundle without requiring a centralized runtime service.
2. Core Commands¶
Build a bundle from the current runtime, registry snapshot, and release evidence:
python skills.py release-bundle-build \
--runtime-root . \
--registry-root ../agent-skill-registry
Verify the manifest, required evidence files, and checksums:
python skills.py release-bundle-verify artifacts/release_bundles/<bundle-id>
Promote a verified bundle into a local environment state:
python skills.py release-bundle-promote \
artifacts/release_bundles/<bundle-id> \
--environment preview
Promote a bundle through the governed product path:
python skills.py release-bundle-promote-gated \
artifacts/release_bundles/<bundle-id> \
--environment dev \
--source-environment preview
Rollback an environment to the previous verified release:
python skills.py release-bundle-rollback --environment preview
3. Bundle Contract¶
Every bundle contains:
bundle_manifest.jsonwith contractrelease_bundle_v1payload/runtime/snapshot of runtime code and deployment-facing assetspayload/registry/snapshot of runtime-consumed registry contentevidence/containing release/readiness/lineage artifacts
The manifest records:
- Bundle ID and timestamp
- Runtime and registry git metadata when available
- SHA-256 checksums for payload and evidence files
- Required evidence file list
4. Environment State Model¶
Promotion writes state under:
artifacts/deployments/<environment>/
Each environment contains:
releases/<bundle-id>/copied immutable bundle contentscurrent.jsonpointer to the active bundlehistory.jsonlappend-only promotion/rollback history
This keeps deployment state explicit and auditable for each local instance.
5. Preview Flow¶
Recommended PR preview flow:
- Run bundle build
- Verify the bundle
- Promote it to
preview - Run targeted runtime checks against the preview instance or preview state
- Attach bundle artifact + preview state to PR evidence
Preview is not required to expose a public URL. For local-instance deployments, preview means a verifiable isolated deployment state that can be exercised before promotion.
GitHub Actions preview runs publish the bundle as artifact release-preview-bundle.
That artifact is the canonical handoff into manual environment promotion.
6. Promotion Flow¶
Recommended promotion path:
previewdevstagingprod
Rules:
- Only verified bundles should be promoted.
- Product-grade promotions should use
release-bundle-promote-gated. - Promotion evidence should include release gate and lineage artifacts.
stagingandprodpromotion should remain gated by the existing policy promotion readiness and release gate controls.- Gated promotion emits
artifacts/release_bundle_promotion_<environment>.json.
For GitHub Actions manual promotion, deployment-promote.yml should receive:
source_run_idfor the workflow run that produced the bundlesource_artifact_name, normallyrelease-preview-bundletarget_environmentas the highest environment to promote in that run
The promotion workflow downloads that exact artifact, resolves the bundled
bundle_manifest.json, verifies the imported bundle, and promotes that same
bundle forward. It does not rebuild a new candidate.
It also resolves the successful Smoke Verification run for the same
head_sha and downloads the smoke/runtime/DX/trend artifacts needed to
re-evaluate release_readiness_gate in promotion context before and after the
promotion chain.
Additional provenance hardening in deployment-promote.yml:
source_run_idmust be a successful run from.github/workflows/deployment-preview.yml- the imported bundle manifest must declare
release_bundle_v1 - the imported bundle must have
bundle_label=pr-preview source.runtime_git.commitin the bundle manifest must exactly match the source runhead_sha- promotion reports include both source run and resolved smoke run metadata
7. Rollback Flow¶
Rollback is pointer-based and bundle-based.
Use rollback when:
- Runtime canary regresses after promotion
- Release gate evidence changes from
gotono-go - Operational health degrades after a bundle switch
After rollback:
- Re-run targeted canary checks
- Reconfirm the active
current.jsonpointer - Record the rollback reason in release notes or incident notes
9. Promotion Reports¶
The gated promotion path writes a promotion report per environment:
artifacts/release_bundle_promotion_dev.jsonartifacts/release_bundle_promotion_staging.jsonartifacts/release_bundle_promotion_prod.json
These reports capture:
- Bundle verification outcome
- Release gate decision used for promotion
- Promotion-readiness evidence status
- Environment transition validation
- Final promotion status and resulting active pointer
Manual promotion also records artifacts/release_bundle_promotion_source.json
with the source workflow run and artifact metadata used for the promotion.
8. Practical Minimum for Product Use¶
Treat deployment DX as product-grade only when all are true:
- PR preview bundle can be built automatically
- Promote commands are documented and repeatable
- Rollback succeeds without manual file copying
- Release bundle always carries traceable evidence
- Local-instance operators can execute the flow without bespoke scripts