mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-24 12:15:52 +00:00
Fix panic
This commit is contained in:
parent
a04b6e4b16
commit
29808eaf24
@ -509,7 +509,7 @@ func (m *managerImpl) podEphemeralStorageLimitEviction(podStats statsapi.PodStat
|
||||
|
||||
// pod stats api summarizes ephemeral storage usage (container, emptyDir, host[etc-hosts, logs])
|
||||
podEphemeralStorageTotalUsage := &resource.Quantity{}
|
||||
if podStats.EphemeralStorage != nil {
|
||||
if podStats.EphemeralStorage != nil && podStats.EphemeralStorage.UsedBytes != nil {
|
||||
podEphemeralStorageTotalUsage = resource.NewQuantity(int64(*podStats.EphemeralStorage.UsedBytes), resource.BinarySI)
|
||||
}
|
||||
podEphemeralStorageLimit := podLimits[v1.ResourceEphemeralStorage]
|
||||
|
Loading…
Reference in New Issue
Block a user