Skip to content

Commit 84e2d4d

Browse files
committed
exporter: silently skip unpacking unknown reference
Signed-off-by: Justin Chadwell <[email protected]>
1 parent 535eac9 commit 84e2d4d

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

exporter/containerimage/export.go

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -367,11 +367,8 @@ func (e *imageExporterInstance) unpackImage(ctx context.Context, img images.Imag
367367
}
368368

369369
ref, ok := src.FindRef(defaultPlatform())
370-
if !ok {
371-
return errors.Errorf("no reference for default platform %s", defaultPlatform())
372-
}
373-
if ref == nil {
374-
// ref has no layers, so nothing to unpack
370+
if !ok || ref == nil {
371+
// platform ref not found, or found platform ref has no layers, so nothing to unpack
375372
return nil
376373
}
377374

0 commit comments

Comments
 (0)