containerd / stargz-snapshotter

Fast container image distribution plugin with lazy pulling
https://github.com/containerd/containerd/issues/3731
Apache License 2.0
1.19k stars 116 forks source link

Tracker issue for adoption status #258

Open AkihiroSuda opened 3 years ago

AkihiroSuda commented 3 years ago

(Updated by @ktock and me (@AkihiroSuda))

Summary

Tools Lazy Pulling of eStargz Chunk Verification Creating eStargz Optimizing eStargz Handling (pull/push/run) eStargz*
Kubernetes ✅ (w/ containerd, CRI-O) ✅ (w/ containerd) ➖ (doesn't create image) ➖ (doesn't create image)
k3s ➖ (doesn't create image) ➖ (doesn't create image)
kind ✅(needs a customized node image) ✅(needs a customized node image) ➖ (doesn't create image) ➖ (doesn't create image)
containerd ➖ (doesn't create image) ➖ (doesn't create image)
CRI-O ➖ (doesn't create image) ➖ (doesn't create image)
Docker
Podman
nerdctl ✅ (manual optimization)
BuildKit
Kaniko
Buildah
ko
go-containerregistry and crane ✅ (manual optimization)
ctr-remote
buildpacks.io
Harbor ✅ (eStargz can be pushed/pulled as a normal OCI image)

Kubernetes and distros

Kubernetes

✅ Lazy pulling is possible by using containerd or CRI-O as CRI runtime

k3s

✅ Supported since k3s v1.22. Doc: https://docs.k3s.io/advanced#enabling-lazy-pulling-of-estargz-experimental

kind

Use ghcr.io/containerd/stargz-snapshotter:0.12.1-kind node image e.g.:

$ kind create cluster --name stargz-demo --image ghcr.io/containerd/stargz-snapshotter:0.12.1-kind

CRI runtimes

containerd

✅ Lazy pulling is supported since containerd 1.4.0

CRI-O

✅ Lazy pulling is supported since v1.22 (which includes https://github.com/cri-o/cri-o/pull/4850)

High-level container engines

Docker (Moby)

✅ Lazy pulling is supported since https://github.com/moby/moby/commit/5c1d6c957b97321c8577e10ddbffe6e01981617a

Podman

✅ Lazy pulling is supported since v3.3.0 (which includes https://github.com/containers/podman/pull/10214)

nerdctl

Lazy pulling of eStargz

✅ Supported since nerdctl 0.0.1 https://github.com/containerd/nerdctl/blob/master/docs/stargz.md

Building eStargz images

✅ Supported since nerdctl 0.5.0 https://github.com/containerd/nerdctl/blob/master/docs/stargz.md

Image builders

BuildKit

Lazy-pulling base images

✅ Supported since BuildKit 0.8.0 https://github.com/moby/buildkit/blob/master/docs/stargz-estargz.md

Building eStargz images

✅ Supported since BuildKit v0.10.

Usage: buildctl build--output type=image,name=example.com/foo,push=true,compression=estargz,oci-mediatypes=true.

Kaniko

Lazy-pulling base images

❌ Won't be possible

Building eStargz images

✅ Supported since Kaniko 1.4.0 https://github.com/GoogleContainerTools/kaniko/pull/1527

Buildah

Lazy-pulling base images

TBD, will happen after Podman supports lazy-pulling

Building eStargz images

TBD

ko

Building eStargz images

✅ Supported since ko 0.7.0 https://github.com/google/ko/pull/271

buildpacks.io

Building eStargz images

✅ Supported since pack 0.16.0, lifecycle 0.10.2

Registry clients

go-containerregistry and crane CLI

Converting image into eStargz

✅Supported since go-containerregistry 0.3.0 https://github.com/google/go-containerregistry/pull/871

Registry

Harbor

✅Harbor Acceleration Service webhook enables converting an OCI image into eStargz on registry side.

https://github.com/goharbor/acceleration-service

ktock commented 3 years ago

Thanks! :+1:

chenk008 commented 3 years ago

Does Podman need to bump containers/storage version to support stargz?

ktock commented 3 years ago

@chenk008

Does Podman need to bump containers/storage version to support stargz?

Yes. You also need https://github.com/containers/image/pull/1109 and https://github.com/containerd/stargz-snapshotter/pull/301 as well. We'll work on downstreaming these patches to Podman/CRI-O once they are merged.

Please check also the current limitation of lazy pulling feature for these runtimes (https://github.com/containers/storage/pull/795#issuecomment-799057091). Summary:

AkihiroSuda commented 2 years ago

Linking

gabrieldemarmiesse commented 2 years ago

In the new Docker desktop, the containerd image store is in beta. I tried it and it used stargz as the default snapshotter. It has rough edges but pretty cool nonetheless

giuseppe commented 8 months ago

@ktock what is needed for chunk validation in Podman/CRI-O/Buildah?

Isn't that part done by the snapshotter itself?

harche commented 8 months ago

@ktock what is needed for chunk validation in Podman/CRI-O/Buildah?

Isn't that part done by the snapshotter itself?

/cc @AkihiroSuda

jonathanbeber commented 1 month ago

I believe crane should be removed as https://github.com/google/go-containerregistry/pull/1660