Skip to content

Commit

Permalink
feat: decrease minimum allowed size for OsDiskSizeGB from 100 to 30
Browse files Browse the repository at this point in the history
  • Loading branch information
bongi23 committed Feb 25, 2025
1 parent e9b1ae6 commit fc42635
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ spec:
default: 128
description: osDiskSizeGB is the size of the OS disk in GB.
format: int32
minimum: 100
minimum: 30
type: integer
tags:
additionalProperties:
Expand Down
2 changes: 1 addition & 1 deletion pkg/apis/crds/karpenter.azure.com_aksnodeclasses.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ spec:
default: 128
description: osDiskSizeGB is the size of the OS disk in GB.
format: int32
minimum: 100
minimum: 30
type: integer
tags:
additionalProperties:
Expand Down
2 changes: 1 addition & 1 deletion pkg/apis/v1alpha2/aksnodeclass.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ type AKSNodeClassSpec struct {
// +optional
VNETSubnetID *string `json:"vnetSubnetID,omitempty"`
// +kubebuilder:default=128
// +kubebuilder:validation:Minimum=100
// +kubebuilder:validation:Minimum=30
// osDiskSizeGB is the size of the OS disk in GB.
OSDiskSizeGB *int32 `json:"osDiskSizeGB,omitempty"`
// ImageID is the ID of the image that instances use.
Expand Down
2 changes: 1 addition & 1 deletion pkg/controllers/nodeclass/hash/suite_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ var _ = Describe("NodeClass Hash Controller", func() {

},
Entry("ImageFamily Drift", &v1alpha2.AKSNodeClass{Spec: v1alpha2.AKSNodeClassSpec{ImageFamily: lo.ToPtr("AzureLinux")}}),
Entry("OSDiskSizeGB Drift", &v1alpha2.AKSNodeClass{Spec: v1alpha2.AKSNodeClassSpec{OSDiskSizeGB: lo.ToPtr(int32(100))}}),
Entry("OSDiskSizeGB Drift", &v1alpha2.AKSNodeClass{Spec: v1alpha2.AKSNodeClassSpec{OSDiskSizeGB: lo.ToPtr(int32(30))}}),
Entry("Tags Drift", &v1alpha2.AKSNodeClass{Spec: v1alpha2.AKSNodeClassSpec{Tags: map[string]string{"keyTag-test-3": "valueTag-test-3"}}}),
)
It("should update AKSNodeClass-hash-version annotation when the AKSNodeClass-hash-version on the NodeClass does not match with the controller hash version", func() {
Expand Down

0 comments on commit fc42635

Please sign in to comment.