Repository navigation
fix: align OS disk sizing with AKS when osDiskSizeGB is unset - #1973
Merged
Robin D. (comtalyst) merged 9 commits intoOct 10, 2026
Merged
Robin D. (comtalyst) merged 9 commits into
Robin D. (comtalyst) merged 9 commits into
Conversation
# Conflicts: # pkg/providers/instancetype/instancetypes.go
Contributor
There was a problem hiding this comment.
π΅ Needs a closer look
It changes API defaulting and storage provisioning across both Azure provisioning paths while depending on another stacked fix.
0 open findings
What changed in this PR
Aligns unset OS disk sizing with AKS defaults across VM and AKS Machine API provisioning.
Changes:
- Resolves per-SKU ephemeral or vCPU-based managed disk profiles.
- Uses resolved sizes for provisioning and advertised capacity.
- Updates CRDs and adds unit, acceptance, and E2E coverage.
| File | Description |
|---|---|
test/βsuites/βnodeclaim/βeph_osdisk_test.go |
Adds auto-sizing E2E coverage. |
pkg/βtest/βnodeclass.go |
Leaves test disk size unset. |
pkg/βproviders/βinstancetype/βsuite_test.go |
Tests sizing, placement, and capacity. |
pkg/βproviders/βinstancetype/βinstancetypes.go |
Implements shared disk-profile resolution. |
pkg/βproviders/βinstancetype/βinstancetype.go |
Reports resolved storage capacity. |
pkg/βproviders/βinstancetype/βinstancetype_test.go |
Adapts test parameters to pointer sizing. |
pkg/βproviders/βinstance/βvminstance.go |
Sends the resolved VM disk size. |
pkg/βproviders/βinstance/βaksmachineinstancehelpers.go |
Sends resolved Machine API disk settings. |
pkg/βproviders/βimagefamily/βresolver.go |
Populates launch templates from resolved profiles. |
pkg/βcloudprovider/βsuite_aksmachineapi_features_test.go |
Covers Machine API auto-sizing. |
pkg/βapis/βv1beta1/βcrd_validation_cel_test.go |
Tests unset and invalid sizing. |
pkg/βapis/βv1beta1/βaksnodeclass.go |
Removes the 128 GB default. |
pkg/βapis/βv1alpha2/βcrd_validation_cel_test.go |
Updates legacy validation tests. |
pkg/βapis/βv1alpha2/βaksnodeclass.go |
Mirrors sizing documentation. |
pkg/βapis/βcrds/βkarpenter.azure.com_aksnodeclasses.yaml |
Updates generated CRD schemas. |
charts/βkarpenter-crd/βtemplates/βkarpenter.azure.com_aksnodeclasses.yaml |
Updates generated chart CRDs. |
π§ Review effort: Balanced
π‘ Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Bevan Arps (theunrepentantgeek)
previously approved these changes
Oct 9, 2026
Bevan Arps (theunrepentantgeek)
left a comment
Member
There was a problem hiding this comment.
Looks good.
/yet-another-code-review found no additional findings.
Carry forward the current-main load-balancer exclusion behavior and Windows/Cilium E2E guard through the stack. Preserve every added and removed line of PR1973's reviewed OS disk autosizing delta.
β¦-size-os-disk-stacked
β¦-size-os-disk-stacked
β¦size-os-disk-stacked
Alex Leites (tallaxes)
approved these changes
Oct 10, 2026
1 of 3 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Depends on: #1869
Stacked copy of: #1723
Fixes Azure/AKS#5503
Description
When osDiskSizeGB is omitted, prefer an ephemeral OS disk at the SKU-supported size (capped at 2040GB).
SKUs without ephemeral support fall back to managed disk defaults by vCPU count (128/256/512/1024GB).
VM and AKS Machine API paths consume the same resolved profile, and reported ephemeral-storage capacity matches the provisioned size.
Explicit values remain bounded to 30-2048GB.
Official reference:
https://learn.microsoft.com/en-us/azure/aks/concepts-storage#default-os-disk-sizing
How was this change tested?
Does this change impact docs?
Release Note