Skip to content

Commit 526defb

Browse files
committed
Fix containerd fails to pull OCI image with non-http(s):// urls
Signed-off-by: Kohei Tokunaga <[email protected]>
1 parent d418660 commit 526defb

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

remotes/docker/fetcher.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,10 @@ func (r dockerFetcher) Fetch(ctx context.Context, desc ocispec.Descriptor) (io.R
5959
log.G(ctx).WithError(err).Debug("failed to parse")
6060
continue
6161
}
62+
if u.Scheme != "http" && u.Scheme != "https" {
63+
log.G(ctx).Debug("non-http(s) alternative url is unsupported")
64+
continue
65+
}
6266
log.G(ctx).Debug("trying alternative url")
6367

6468
// Try this first, parse it

0 commit comments

Comments
 (0)