Skip to content

Commit

Permalink
Add VmReserved to InstanceTypeOverhead
Browse files Browse the repository at this point in the history
Signed-off-by: jukie <[email protected]>
  • Loading branch information
jukie committed Sep 17, 2024
1 parent dd92bc3 commit 1c55cea
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion pkg/cloudprovider/types.go
Original file line number Diff line number Diff line change
Expand Up @@ -220,10 +220,12 @@ type InstanceTypeOverhead struct {
SystemReserved corev1.ResourceList
// EvictionThreshold returns the resources used to maintain a hard eviction threshold
EvictionThreshold corev1.ResourceList
// VmReserved returns the additional overhead resources reserved for things like hypervisor or OS
VmReserved corev1.ResourceList

Check failure on line 224 in pkg/cloudprovider/types.go

View workflow job for this annotation

GitHub Actions / presubmit (1.25.x)

ST1003: struct field VmReserved should be VMReserved (stylecheck)

Check failure on line 224 in pkg/cloudprovider/types.go

View workflow job for this annotation

GitHub Actions / presubmit (1.26.x)

ST1003: struct field VmReserved should be VMReserved (stylecheck)

Check failure on line 224 in pkg/cloudprovider/types.go

View workflow job for this annotation

GitHub Actions / presubmit (1.27.x)

ST1003: struct field VmReserved should be VMReserved (stylecheck)

Check failure on line 224 in pkg/cloudprovider/types.go

View workflow job for this annotation

GitHub Actions / presubmit (1.28.x)

ST1003: struct field VmReserved should be VMReserved (stylecheck)

Check failure on line 224 in pkg/cloudprovider/types.go

View workflow job for this annotation

GitHub Actions / presubmit (1.29.x)

ST1003: struct field VmReserved should be VMReserved (stylecheck)

Check failure on line 224 in pkg/cloudprovider/types.go

View workflow job for this annotation

GitHub Actions / presubmit (1.30.x)

ST1003: struct field VmReserved should be VMReserved (stylecheck)
}

func (i InstanceTypeOverhead) Total() corev1.ResourceList {
return resources.Merge(i.KubeReserved, i.SystemReserved, i.EvictionThreshold)
return resources.Merge(i.KubeReserved, i.SystemReserved, i.EvictionThreshold, i.VmReserved)
}

// An Offering describes where an InstanceType is available to be used, with the expectation that its properties
Expand Down

0 comments on commit 1c55cea

Please sign in to comment.