Bound images referenced by tag@digest are pruned right after being pulled

Offen
#2,640 0 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen

Maintainer antworten meist innerhalb von 2 Tagen

Dieses Issue hat noch niemand übernommen.

Bewertung

Schwierigkeit
3/5
Geschätzter Aufwand
1-2 Tage
Anfängerfreundlichkeit
71/100
Issue-Typ
Bug
Klarheit
Klar beschrieben
Aktivitätsstatus
Aktiv
Tech-Stack
rust
Bereich
backend, devops

Rechercherichtung

The issue points to image retention in crates/lib/src/deploy.rs and name handling in crates/lib/src/podstorage.rs. Read the prune comparison around the linked lines, then reproduce with the described .container binding and bootc switch. Done when a bound repo:tag@sha256:digest image remains available after pruning and the reported reboot failure is prevented.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Beschreibung

A logically bound image referenced as repo:tag@digest is pulled by bootc switch, then pruned in the same command:

Fetching bound image: docker.io/vaultwarden/server:1.37.5-alpine@sha256:bbe684a0…...done (3 seconds)
Bound images stored: 1
Deploying...done (6 seconds)
Pruned images: 1 (layers: 5, objsize: 73.9 kB)

After the reboot, the app fails with image not known (Pull=never).

Podman stores a repo:tag@digest pull under the name repo@digest, without the tag. The prune keeps an image only if one of its names equals an Image= string exactly:

https://github.com/bootc-dev/bootc/blob/00574d53bd49525cf1f6a58aa0ac259eaef443b3/crates/lib/src/deploy.rs#L461

https://github.com/bootc-dev/bootc/blob/00574d53bd49525cf1f6a58aa0ac259eaef443b3/crates/lib/src/podstorage.rs#L418-L427

so docker.io/vaultwarden/server:1.37.5-alpine@sha256:… never matches docker.io/vaultwarden/server@sha256:….

Reproduce: bind an image with Image=<repo>:<tag>@sha256:<digest> in a .container linked from /usr/lib/bootc/bound-images.d/, then bootc switch to it. Seen with bootc 1.17.1 (Fedora 45); main has the same code. A digest-only reference works.

Vorherrschende Sprache
Rust
Sterne
2.3k
Forks
230
Ø Merge
2 T. 11 Std.
Gemergte PRs (30 T.)
42

Entwicklungsumgebung

Erste Schritte

  1. Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
  2. Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
  3. Forken Sie das Repository und arbeiten Sie in einem Branch.
  4. Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.

Mehr aus bootc-dev/bootc

Alle Issues in bootc-dev/bootc

Ähnliche Issues

Weitere Issues zu Rust

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.