Skip to content

Commit

Permalink
Fix memory mappings (#13)
Browse files Browse the repository at this point in the history
  • Loading branch information
lucklypriyansh-2 authored Oct 9, 2023
1 parent f67e09b commit 4b27b39
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion internal/utils/utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ func roundUpToNearest(value int64, list []int64) int64 {
func GetPodResource(podSpec corev1.PodSpec) (cpu int64, memory int64) {
allowedCPUValues := []int64{1, 2, 3, 4, 6, 8, 12, 16}

allowedMemoryValues := []int64{1024, 2048, 3, 4, 5, 6, 12, 16, 24, 30} // in GB
allowedMemoryValues := []int64{1024, 2048, 3072, 4 * 1024, 5 * 1024, 6 * 1024, 12 * 1024, 16 * 1024, 24 * 1024, 30 * 1024} // in GB

for _, container := range podSpec.Containers {
// Convert milliCPU to cores and round to nearest value in the list
Expand Down

0 comments on commit 4b27b39

Please sign in to comment.