Skip to content

feat(simulate): record build and deploy callbacks as stubbed effects with gating - #360

Merged
joshua-temple merged 2 commits into
mainfrom
feat/simulator-deploy-stub
Jun 25, 2026
Merged

joshua-temple merged 2 commits into
mainfrom
feat/simulator-deploy-stub

Conversation

@joshua-temple

Copy link
Copy Markdown
Collaborator

The simulator validates cascade's orchestration, not the user's build and deploy scripts, but nothing made that boundary explicit or let a user preview gating without running anything.

This adds a deploy-stub model that records each manifest build and deploy callback as a stubbed effect with a configurable outcome (default success). Per-callback failure or skipped outcomes are injectable programmatically via WithDeployResults and on the CLI via a repeatable --deploy-result name=success|failure|skipped flag. A failed deploy gates the simulated finalize, mirroring the real gateOnDeployResults rules. The boundary is documented at the seam and surfaced as a note in cascade simulate output. Additive only: no schema or generator change, and a manifest with no callbacks renders unchanged.

Verification: go build, go test, and golangci-lint all green; new unit tests cover the model, the default-success path, and the failure-gated finalize.

Closes #313.

…with gating

Signed-off-by: Joshua Temple <joshua.temple@stablekernel.com>
Comment thread internal/simulate/deploy_stub.go Fixed
Comment thread internal/simulate/deploy_stub.go Fixed
Signed-off-by: Joshua Temple <joshua.temple@stablekernel.com>
@joshua-temple
joshua-temple enabled auto-merge (squash) June 25, 2026 18:47
@joshua-temple
joshua-temple merged commit 08b9d7b into main Jun 25, 2026
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(simulate): deploy-stub model and the orchestration-not-deploys boundary

2 participants