Enhancement: Protect k3s VMs from accidental replacement #46

Merged
claude-bot Bot merged 1 commits from enhancement/protect-k3s-vms into main 2026-11-22 03:10:09 +01:00

Why

A stale Pulumi state can plan new VMs for machines that already exist. With protect: true, Pulumi fails instead of deleting or replacing a k3s VM.

What changes

All six k3s VMs get protect: true. In-place updates such as CPU, RAM and SSH keys still work. To replace a VM on purpose, run pulumi state unprotect <urn> first.

This changes nothing on the VMs. 01-proxmox-infra only deploys through manual dispatch, so merging does not start a deploy. The protection takes effect after the next pulumi up that includes the VMs.

Verification

npm run typecheck passes. A preview targeting the six VMs shows them locked with 27 unchanged. That local run also included uncommitted Ansible code, so the PR preview is the check for this commit alone.

## Why A stale Pulumi state can plan new VMs for machines that already exist. With `protect: true`, Pulumi fails instead of deleting or replacing a k3s VM. ## What changes All six k3s VMs get `protect: true`. In-place updates such as CPU, RAM and SSH keys still work. To replace a VM on purpose, run `pulumi state unprotect <urn>` first. This changes nothing on the VMs. `01-proxmox-infra` only deploys through manual dispatch, so merging does not start a deploy. The protection takes effect after the next `pulumi up` that includes the VMs. ## Verification `npm run typecheck` passes. A preview targeting the six VMs shows them locked with 27 unchanged. That local run also included uncommitted Ansible code, so the PR preview is the check for this commit alone.
claude-bot Bot added 1 commit 2026-11-22 03:08:51 +01:00
enhancement(proxmox-infra): protect k3s VMs from replacement
Deploy Proxmox Infra / Pulumi Deploy (pull_request) Skipped
Deploy Proxmox Infra / Pulumi Preview (pull_request) Successful in 1m0s
c1e409780d
A stale state can make Pulumi plan new VMs for machines that already exist. Protection makes such an update fail instead of being applied.
claude-bot Bot merged commit 9e0ce35712 into main 2026-11-22 03:10:09 +01:00
Sign in to join this conversation.