3.6 KiB
3.6 KiB
Bid-MVP Factory Control Planes Plan (ljwx-deploy, refreshed on 2026-03-03)
Phase 0 Inventory
Existing
- Workflows exist under
.github/workflows/:nightly-evidence.ymlnightly-auto-repair.ymldeploy-repo-gate.ymlbuild-promoter-image.yml
- Evidence control plane exists:
evidence/schema/evidence-record.schema.jsonevidence/schema/evidence.schema.jsonevidence/records/(directory tracked)scripts/evidence/collect.pyscripts/evidence/validate.pyevidence/index.json,evidence/summary/latest.md
- Pages dashboard source exists in both
pages/andsite/(needs consolidation decision). - Release queue + promoter exists:
release/queue.yaml,release/services.yamlscripts/promoter/promote.py,scripts/promoter/deploy_promoter.py,scripts/promoter/validate_queue.py- CronJob manifests:
infra/factory/deploy-promoter-cronjob.yaml,k8s/promoter/deploy-promoter-cronjob.yaml
- Smoke loop exists:
scripts/smoke/run_smoke.py,scripts/smoke/targets.jsoninfra/factory/smoke-runner-cronjob.yaml
- Auto-repair loop exists:
repairs/recipes.yamlscripts/repair/run.sh,scripts/repair/run_repair.py,scripts/repair/diagnose.py- orchestration docs/scripts:
infra/factory/INTEGRATION_RUN_ALL.md,scripts/factory/run_all_dev.sh,TEST.md
Current Gap / To Improve
- Two-cluster invariant hardening (required):
- Same GitOps code must support both local server
k3sand China mainland dev serverOrbStack k3s. - Differences must be represented via overlays/values/env only, no forked logic or duplicated pipelines.
- Same GitOps code must support both local server
- Promoter implementation appears duplicated (
promote.pyanddeploy_promoter.py):- choose one canonical entrypoint to avoid drift and behavioral mismatch.
- Queue state alignment:
- ensure docs/code agree on
pending/promoted/failed/supersededsemantics and data placement.
- ensure docs/code agree on
- Pages source alignment:
- choose one source directory (
pages/orsite/) and document workflow contract.
- choose one source directory (
- Deploy gate hardening:
- verify gate blocks unauthorized file changes and validates queue/evidence schemas deterministically.
Existing promoter/test-runner/evidence/pages status
- Promoter: present.
- Test-runner/smoke runner: present.
- Evidence model/feed: present.
- Pages/gh-pages publishing: present.
- Conclusion: Phases 2-5 are largely implemented; next step is consistency hardening and elimination of drift.
Planned File Changes (next deploy iterations)
scripts/promoter/*(canonicalize single promoter path and behavior)release/README.md,release/queue.yaml(shape/field consistency).github/workflows/nightly-evidence.yml+ docs (single pages source contract)docs/pages.md,docs/ops-runbook.md(two-k3s same-code rule and runbook precision)argocd-apps/and/orapps/*/overlays/*(if overlay naming normalization is needed for dual k3s)
Local Validation Commands
test -f PLAN.md && sed -n '1,260p' PLAN.mdpython3 scripts/evidence/validate.pypython3 scripts/evidence/collect.py --out evidence/index.json --summary evidence/summary/latest.mdpython3 scripts/promoter/validate_queue.py --queue release/queue.yamlpython3 scripts/promoter/promote.py --dry-run --skip-registry-checkpython3 scripts/smoke/run_smoke.py --dry-runpython3 scripts/repair/diagnose.py --helppython3 scripts/repair/run_repair.py --help
Commit Plan
phase0(deploy): refresh inventory planphase3(deploy): promoter/queue canonicalization + dual-k3s overlay rule hardeningphase4(deploy): smoke/evidence consistency hardeningphase5(deploy): auto-repair determinism and gate tightening