Skip to content

feat(gce): add boot disk auto-delete warning rule - #148

Open
gokulr94 wants to merge 2 commits into
GoogleCloudPlatform:mainfrom
gokulr94:main
Open

feat(gce): add boot disk auto-delete warning rule#148
gokulr94 wants to merge 2 commits into
GoogleCloudPlatform:mainfrom
gokulr94:main

Conversation

@gokulr94

Copy link
Copy Markdown

Add WARN/2026_001 to check if boot disks have auto-delete enabled. When disabled, VMs leave orphaned disks after deletion, causing unexpected storage costs.

  • Skips GKE and Dataproc managed instances
  • Reports warning for boot disks with autoDelete=false

@gokulr94
gokulr94 marked this pull request as ready for review January 20, 2026 17:00
@gokulr94
gokulr94 force-pushed the main branch 2 times, most recently from a148f25 to abf3184 Compare January 22, 2026 05:21
Add WARN/2026_001 to check if boot disks have auto-delete enabled.
When disabled, VMs leave orphaned disks after deletion,
causing unexpected storage costs.

- Skips GKE and Dataproc managed instances
- Reports warning for boot disks with autoDelete=false
The error message for missing instanceTemplate was not interpolating
the MIG name due to missing f-string prefix. This caused the literal
string '{self.name}' to be shown instead of the actual MIG name.
@gokulr94

Copy link
Copy Markdown
Author

Hi, could you please approve the workflow run?

I added an additional commit with a fix for a missing f-string prefix in the MIG template error message (gce.py:241). The string was not interpolating the MIG name correctly.

Changes in this PR:

  1. feat(gce): add boot disk auto-delete warning rule (WARN/2026_001)
  2. fix(gce): add missing f-string prefix in MIG template error message

Both changes have been tested locally - all GCE tests pass.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant