Skip to content

Commit

Permalink
Merge pull request #12318 from sharifelgamal/fix-pause
Browse files Browse the repository at this point in the history
pause each container separately
  • Loading branch information
sharifelgamal authored Aug 20, 2021
2 parents 2fe2086 + b6bbf9f commit 89a322e
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions pkg/minikube/cruntime/cri.go
Original file line number Diff line number Diff line change
Expand Up @@ -134,10 +134,9 @@ func pauseCRIContainers(cr CommandRunner, root string, ids []string) error {
args = append(args, "--root", root)
}
args = append(args, "pause")
cargs := args
for _, id := range ids {
cargs = append(cargs, id)
if _, err := cr.RunCmd(exec.Command("sudo", cargs...)); err != nil {
args := append(args, id)
if _, err := cr.RunCmd(exec.Command("sudo", args...)); err != nil {
return errors.Wrap(err, "runc")
}
}
Expand Down

0 comments on commit 89a322e

Please sign in to comment.