mirror of https://github.com/k3s-io/k3s
kubelet: force filterContainerID to empty string when removeAll is true
parent
d39eac929f
commit
2aba27da86
|
@ -99,6 +99,7 @@ func (p *podContainerDeletor) deleteContainersInPod(filterContainerID string, po
|
||||||
containersToKeep := p.containersToKeep
|
containersToKeep := p.containersToKeep
|
||||||
if removeAll {
|
if removeAll {
|
||||||
containersToKeep = 0
|
containersToKeep = 0
|
||||||
|
filterContainerID = ""
|
||||||
}
|
}
|
||||||
|
|
||||||
for _, candidate := range getContainersToDeleteInPod(filterContainerID, podStatus, containersToKeep) {
|
for _, candidate := range getContainersToDeleteInPod(filterContainerID, podStatus, containersToKeep) {
|
||||||
|
|
Loading…
Reference in New Issue