Skip to content

feat: add non-destructive apply strategy - #923

Open
therunnas wants to merge 2 commits into
padok-team:mainfrom
therunnas:fix/non-destructive-apply
Open

feat: add non-destructive apply strategy#923
therunnas wants to merge 2 commits into
padok-team:mainfrom
therunnas:fix/non-destructive-apply

Conversation

@therunnas

@therunnas therunnas commented Jun 3, 2026

Copy link
Copy Markdown

Closes #559

What changes did you make?

Adds spec.remediationStrategy.nonDestructiveApply to TerraformLayer and TerraformRepository.

When both autoApply and nonDestructiveApply are enabled, Burrito skips creating an apply TerraformRun if the latest plan summary includes resources to delete.

This also updates the generated CRDs, Helm CRDs, static install manifest, DeepCopy output, and user documentation.

How has this been tested?

  • go test ./api/v1alpha1
  • go test ./internal/controllers/terraformlayer -run 'TestApplyNeeded|TestHasDestructiveChanges'
  • go test ./internal/controllers/terraformlayer -run 'TestReconcileBlocksDestructiveFreshPlanWhenNonDestructiveApplyEnabled|TestApplyNeededBlocksDestructivePlanWhenNonDestructiveApplyEnabled|TestHasDestructiveChanges'

The full TerraformLayer controller suite ran 133/133 specs successfully on Windows with envtest assets, but failed during envtest teardown because Windows process signaling for etcd/kube-apiserver is not supported.

@github-project-automation github-project-automation Bot moved this to 📋 Backlog in Burrito Jun 3, 2026

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: c90fc9c495

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread internal/controllers/terraformlayer/states.go
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Status: 📋 Backlog

Development

Successfully merging this pull request may close these issues.

Add setting to prevent burrito from destroying resources

1 participant