Skip to main content

Targeted replan for Pulumi stacks

Targeted replan works for Terraform and OpenTofu stacks. On a Pulumi stack the API returns "replan is only supported for Terraform and OpenTofu stacks", and the Changes view has no resource selection because "detailed resource changes are only available for Terraform, OpenTofu and Terragrunt stacks, not Pulumi; use changesV2 for this run".

We want the same flow for Pulumi. A tracked run reaches Unconfirmed. The user selects resources in the Changes view and presses Replan. Spacelift plans again with `pulumi preview --target <urn>` for each selected resource, and applies with `pulumi up --target <urn>`. The run stops at Unconfirmed again with the reduced plan.

Pulumi already supports `--target` on preview and up, and the changesV2 data has the URN for each resource. The URN is the address Pulumi expects.

Our use case is a stack with unrelated pending changes that need their own review. Today we run a task with pulumi up `--target <urn> --yes`. That skips the plan and confirm steps, and the approver sees a command string instead of a plan.
Workaround
Problem
poor UX

Log in to comment and vote

No comments yet

Be the first to share your thoughts.