Skip to content

Commit

Permalink
Merge pull request #7968 from afbjorklund/podman-slow
Browse files Browse the repository at this point in the history
Don't show any podman hint about restarting sudo
  • Loading branch information
medyagh authored May 3, 2020
2 parents 100ba9b + 743f9f7 commit 453b5e6
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion pkg/drivers/kic/oci/cli_runner.go
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,10 @@ func runCmd(cmd *exec.Cmd, warnSlow ...bool) (*RunResult, error) {
if warn {
if elapsed > warnTime {
out.WarningT(`Executing "{{.command}}" took an unusually long time: {{.duration}}`, out.V{"command": rr.Command(), "duration": elapsed})
out.ErrT(out.Tip, `Restarting the {{.name}} service may improve performance.`, out.V{"name": cmd.Args[0]})
// Don't show any restarting hint, when running podman locally (on linux, with sudo). Only when having a service.
if cmd.Args[0] != "sudo" {
out.ErrT(out.Tip, `Restarting the {{.name}} service may improve performance.`, out.V{"name": cmd.Args[0]})
}
}

if ctx.Err() == context.DeadlineExceeded {
Expand Down

0 comments on commit 453b5e6

Please sign in to comment.