Skip to content

containerd-integration: images pulled by digest don't show in image list #44579

@thaJeztah

Description

@thaJeztah

Description

When pulling an image by digest, the image does not show up in docker image ls

Reproduce

docker image pull busybox@sha256:fcd85228d7a25feb59f101ac3a955d27c80df4ad824d65f5757a954831450185
fcd85228d7a2: Download complete
e68659cdc5b2: Download complete
73a648b1404c: Download complete
3e32979327a9: Download complete
docker.io/library/busybox@sha256:fcd85228d7a25feb59f101ac3a955d27c80df4ad824d65f5757a954831450185

Neither docker image ls, nor docker image ls -a or docker image ls --digests show the image:

docker image ls
REPOSITORY       TAG          IMAGE ID       CREATED        SIZE

docker image ls -a
REPOSITORY       TAG          IMAGE ID       CREATED        SIZE

docker image ls --digests
REPOSITORY       TAG          DIGEST                                                                    IMAGE ID       CREATED        SIZE

Note that the same happens with the "docker" image:tag@digest format.

The image is present though, as docker image inspect works;

docker image inspect busybox@sha256:fcd85228d7a25feb59f101ac3a955d27c80df4ad824d65f5757a954831450185
[
    {
        "Id": "sha256:fcd85228d7a25feb59f101ac3a955d27c80df4ad824d65f5757a954831450185",
        "RepoTags": null,
        "RepoDigests": [
            "busybox@sha256:fcd85228d7a25feb59f101ac3a955d27c80df4ad824d65f5757a954831450185"
        ],
        "...": "..."
    }
]

Workaround: manually tag the image after pulling;

docker tag busybox@sha256:fcd85228d7a25feb59f101ac3a955d27c80df4ad824d65f5757a954831450185 busybox:latest

docker image ls
REPOSITORY       TAG          IMAGE ID       CREATED         SIZE
busybox          latest       fcd85228d7a2   6 seconds ago   832kB

Expected behavior

The image to be found as "untagged" (but with digest)

docker version

Client:
 Cloud integration: v1.0.29
 Version:           20.10.21
 API version:       1.41
 Go version:        go1.18.7
 Git commit:        baeda1f
 Built:             Tue Oct 25 18:01:18 2022
 OS/Arch:           darwin/arm64
 Context:           default
 Experimental:      true

Server: Docker Desktop 4.15.0 (93002)
 Engine:
  Version:          22.06.0-beta.0-902-g2708be0db4.m
  API version:      1.43 (minimum version 1.12)
  Go version:       go1.18.4
  Git commit:       2708be0db4
  Built:            Wed Nov 23 09:32:50 2022
  OS/Arch:          linux/arm64
  Experimental:     true
 containerd:
  Version:          1.6.10
  GitCommit:        770bd0108c32f3fb5c73ae1264f7e503fe7b2661
 runc:
  Version:          1.1.4
  GitCommit:        v1.1.4-0-g5fd4c4d
 docker-init:
  Version:          0.19.0
  GitCommit:        de40ad0

docker info

Client:
 Context:    default
 Debug Mode: false
 Plugins:
  base: Identify base image (Docker Inc., vn/a)
  buildx: Docker Buildx (Docker Inc., v0.9.1)
  compose: Docker Compose (Docker Inc., v2.13.0)
  dev: Docker Dev Environments (Docker Inc., v0.0.5)
  extension: Manages Docker extensions (Docker Inc., v0.2.16)
  sbom: View the packaged-based Software Bill Of Materials (SBOM) for an image (Anchore Inc., 0.6.0)
  scan: Docker Scan (Docker Inc., v0.22.0)
  shell: Open a browser shell on the Docker Host. (thaJeztah, v0.0.1)

Server:
 Containers: 48
  Running: 12
  Paused: 0
  Stopped: 36
 Images: 12
 Server Version: 22.06.0-beta.0-902-g2708be0db4.m
 Storage Driver: stargz
  driver-type: io.containerd.snapshotter.v1
 Logging Driver: json-file
 Cgroup Driver: cgroupfs
 Cgroup Version: 2
 Plugins:
  Volume: local
  Network: bridge host ipvlan macvlan null overlay
  Log: awslogs fluentd gcplogs gelf journald json-file local logentries splunk syslog
 Swarm: active
  NodeID: bfpr7gj1w767qwq37qta7kqts
  Is Manager: true
  ClusterID: crv7mpxcck85em4ocnfci4esi
  Managers: 1
  Nodes: 1
  Default Address Pool: 10.0.0.0/8
  SubnetSize: 24
  Data Path Port: 4789
  Orchestration:
   Task History Retention Limit: 5
  Raft:
   Snapshot Interval: 10000
   Number of Old Snapshots to Retain: 0
   Heartbeat Tick: 1
   Election Tick: 10
  Dispatcher:
   Heartbeat Period: 5 seconds
  CA Configuration:
   Expiry Duration: 3 months
   Force Rotate: 0
  Autolock Managers: false
  Root Rotation In Progress: false
  Node Address: 192.168.65.3
  Manager Addresses:
   192.168.65.3:2377
 Runtimes: io.containerd.runc.v2 runc
 Default Runtime: runc
 Init Binary: docker-init
 containerd version: 770bd0108c32f3fb5c73ae1264f7e503fe7b2661
 runc version: v1.1.4-0-g5fd4c4d
 init version: de40ad0
 Security Options:
  seccomp
   Profile: builtin
  cgroupns
 Kernel Version: 5.15.49-linuxkit
 Operating System: Docker Desktop
 OSType: linux
 Architecture: aarch64
 CPUs: 5
 Total Memory: 5.8GiB
 Name: docker-desktop
 ID: c8ca0b32-cd5f-4ad2-9a97-bc30ebe413d4
 Docker Root Dir: /var/lib/docker
 Debug Mode: false
 HTTP Proxy: http.docker.internal:3128
 HTTPS Proxy: http.docker.internal:3128
 No Proxy: hubproxy.docker.internal
 Registry: https://index.docker.io/v1/
 Labels:
 Experimental: true
 Insecure Registries:
  hubproxy.docker.internal:5000
  127.0.0.0/8
 Live Restore Enabled: false

Additional Info

Docker Desktop 4.16 with containerd-integration enabled

Metadata

Metadata

Assignees

No one assigned

    Labels

    area/imagesImage Distributioncontainerd-integrationIssues and PRs related to containerd integrationkind/bugBugs are bugs. The cause may or may not be known at triage time so debugging may be needed.

    Type

    No type

    Projects

    Status

    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions