Repository navigation
fix: align kube-reserved limits with Machine API - #1998
Merged
Merged
Conversation
Contributor
There was a problem hiding this comment.
π’ Approval recommended
The validation, generated schemas, boundary coverage, and dependent fixtures are consistent.
0 open findings
What changed in this PR
Aligns kube-reserved validation with AKS Machine API minimums.
Changes:
- Requires CPU β₯140m and memory β₯750Mi.
- Adds boundary validation tests for both API versions.
- Updates valid test fixtures from 512Mi to 1024Mi.
| File | Description |
|---|---|
test/βsuites/βintegration/βkubeletconfig_test.go |
Updates the integration fixture and assertion. |
pkg/βproviders/βinstancetype/βsuite_test.go |
Updates acceptance and cache test fixtures. |
pkg/βproviders/βinstancetype/βinstancetype_test.go |
Updates scheduling override tests. |
pkg/βproviders/βinstance/βaksmachineinstancehelpers_test.go |
Updates Machine API mapping coverage. |
pkg/βcloudprovider/βsuite_aksmachineapi_features_test.go |
Updates cloud-provider feature fixtures. |
pkg/βapis/βv1beta1/βcrd_validation_cel_test.go |
Adds minimum boundary tests. |
pkg/βapis/βv1beta1/βaksnodeclass.go |
Defines the new validation minimums. |
pkg/βapis/βv1beta1/βaksnodeclass_hash_test.go |
Updates the valid hash fixture. |
pkg/βapis/βv1alpha2/βcrd_validation_cel_test.go |
Adds legacy-version boundary tests. |
pkg/βapis/βv1alpha2/βaksnodeclass.go |
Mirrors validation in the legacy schema. |
pkg/βapis/βcrds/βkarpenter.azure.com_aksnodeclasses.yaml |
Updates the generated CRD schema. |
charts/βkarpenter-crd/βtemplates/βkarpenter.azure.com_aksnodeclasses.yaml |
Updates the generated Helm CRD template. |
π§ Review effort: Balanced
π‘ Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Alex Leites (tallaxes)
approved these changes
Oct 13, 2026
Mark Ibrahim (mxj220)
approved these changes
Oct 13, 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.
(AI-generated)
Description
Reject kube-reserved CPU values below 140 millicores and memory values below 750 MiB at AKSNodeClass CRD admission in both API versions, matching the AKS Machine API server contract.
Accepted values continue to pass through unchanged. The positive integration scenario and related valid fixtures now use 1024 MiB; there is no clamping, fallback, or mapper behavior change.
How was this change tested?
go test ./test/suites/integration -run '^$' -count=1GOPROXY=https://proxy.golang.org,direct make verifyGOPROXY=https://proxy.golang.org,direct make testDoes this change impact docs?
Release Note