Skip to content

Commit 532c0ef

Browse files
authored
Merge pull request #1457 from saschagrunert/pull-timeout-fix
Fix `pull-timeout` flag for `crictl pull`
2 parents 6b68854 + 3689ac1 commit 532c0ef

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

cmd/crictl/image.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ var pullImageCommand = &cli.Command{
126126
return err
127127
}
128128
}
129-
timeout := c.Duration("timeout")
129+
timeout := c.Duration("pull-timeout")
130130
r, err := PullImageWithSandbox(imageClient, imageName, auth, sandbox, ann, timeout)
131131
if err != nil {
132132
return fmt.Errorf("pulling image: %w", err)
@@ -664,7 +664,7 @@ func PullImageWithSandbox(client internalapi.ImageManagerService, image string,
664664
defer cancel()
665665

666666
if timeout > 0 {
667-
logrus.Debugf("Using context with timeout of %s", timeout)
667+
logrus.Debugf("Using pull context with timeout of %s", timeout)
668668
ctx, cancel = context.WithTimeout(ctx, timeout)
669669
defer cancel()
670670
}

0 commit comments

Comments
 (0)