Jelajahi Sumber

Merge pull request #47454 from vvoland/c8d-pull-pullingfslayer-truncated

c8d/pull: Output truncated id for `Pulling fs layer`
Paweł Gronowski 1 tahun lalu
induk
melakukan
94f9f39b24
1 mengubah file dengan 3 tambahan dan 1 penghapusan
  1. 3 1
      daemon/containerd/image_pull.go

+ 3 - 1
daemon/containerd/image_pull.go

@@ -21,6 +21,7 @@ import (
 	"github.com/docker/docker/internal/compatcontext"
 	"github.com/docker/docker/pkg/progress"
 	"github.com/docker/docker/pkg/streamformatter"
+	"github.com/docker/docker/pkg/stringid"
 	ocispec "github.com/opencontainers/image-spec/specs-go/v1"
 	"github.com/pkg/errors"
 )
@@ -118,7 +119,8 @@ func (i *ImageService) pullTag(ctx context.Context, ref reference.Named, platfor
 			sentSchema1Deprecation = true
 		}
 		if images.IsLayerType(desc.MediaType) {
-			progress.Update(out, desc.Digest.String(), "Pulling fs layer")
+			id := stringid.TruncateID(desc.Digest.String())
+			progress.Update(out, id, "Pulling fs layer")
 		}
 		if images.IsManifestType(desc.MediaType) {
 			if !sentPullingFrom {