liveBook · Manning

Dangling image

As explained in Podman in Action: Secure, rootless containers for Kubernetes, microservices, and more

A dangling image is a container image whose tag and repository reference are both absent after being superseded by another image.

A dangling image is a container image left without a repository name or tag after a newer image supersedes it. Podman displays it as <none> <none> while retaining its image ID in local storage. section 2.2.2 section 2.3.2

Use the image ID to manage a dangling image:

  • Restore a usable name with podman tag if the replacement fails. section 2.3.2
  • Remove it explicitly with podman rmi when it is no longer needed. section 2.3.2
  • Remove dangling images in bulk with podman image prune; use --all only when broader unused-image removal is intended. section 2.2.7

Automated replacement

Running podman build -t quay.io/rhatdan/myimage ./myapp replaces the tag on the newer image and leaves the previous image listed as <none> <none>. Repeated builds can waste storage until pruning removes the obsolete images. section 2.3.2

$ podman images
REPOSITORY                   TAG        IMAGE ID       CREATED     SIZE
localhost/myimage         latest    2c7e43d88038  46 hours ago   462 MB
registry.access.redhat
.com/ubi8/httpd-24      latest    8594be0a0b57   5 weeks ago   462 MB
registry.access.redhat
.com/ubi8               latest    ad42391b9b46   5 weeks ago   234 MB

Inspect repository, tag, image ID, creation time, and size with podman images; use --all to include images not currently in use. section 2.2.2

How Podman in Action: Secure, rootless containers for Kubernetes, microservices, and more covers it

How deep it goes
Explains naming state, image-ID recovery, and prune behavior, but defers image-storage internals.
Examples
Uses podman images output, repeated podman build commands, podman tag recovery, podman rmi removal, and podman image prune.
What you can do after
Operate/configure it by identifying, restoring, removing, or pruning untagged images with Podman commands.
How it connects
Connects image tags, image IDs, container images, image builds, and Podman image pruning.

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Podman in Action: Secure, rootless containers for Kubernetes, microservices, and more. The section links point to the parts of the book it draws on.