User-defined Playground

containerd Playground

An industry-standard container runtime with an emphasis on simplicity, robustness and portability.

Startup configuration
containerd
containerd playground: An industry-standard container runtime with an emphasis on simplicity, robustness and portability.

๐Ÿ”ง System Components

  • containerd: The core container runtime daemon.
  • runc/crun/runsc: Low-level OCI runtime implementations.

๐Ÿ› ๏ธ Tools

  • ctr: A low-level CLI for interacting with containerd directly.
  • nerdctl: A Docker-compatible CLI for containerd, easier for day-to-day use.

๐ŸŽฏ Getting Started

Pull and list images

nerdctl
ctr
nerdctl pull hello-world:latest

nerdctl images
ctr images pull docker.io/library/hello-world:latest

ctr images ls

Run containers

nerdctl
ctr
nerdctl run --rm hello-world:latest
ctr run --rm docker.io/library/hello-world:latest hello

Running a container with a selected OCI runtime

nerdctl
ctr
nerdctl run -t --runtime runc docker.io/library/hello-world:latest
nerdctl run -t --runtime crun docker.io/library/hello-world:latest

nerdctl run -t --runtime runsc ghcr.io/containerd/busybox:latest dmesg
ctr image pull docker.io/library/hello-world:latest
ctr image pull ghcr.io/containerd/busybox:latest

ctr run --rm -t --runtime io.containerd.runc.v2 --runc-binary /usr/local/sbin/runc docker.io/library/hello-world:latest runc
ctr run --rm -t --runtime io.containerd.runc.v2 --runc-binary /usr/local/sbin/crun docker.io/library/hello-world:latest crun

ctr run --rm -t --runtime io.containerd.runsc.v1 ghcr.io/containerd/busybox:latest runsc dmesg

๐Ÿค” Choosing the Right Tool

Use CaseRecommended ToolWhy
Learning the basicsnerdctlFamiliar commands, less complexity
Understanding containerd internalsctrDirect API access, explicit control
Production automationctrMinimal overhead, precise control
Development workflowsnerdctlBuild, compose, volume support

๐Ÿท๏ธ Versions

  • OCI runtime
    • runc: v1.4.2
    • crun: 1.27.1
    • runsc: latest from the gVisor apt repository
  • containerd: 2.3.1
  • CNI plugins: v1.9.1
  • nerdctl: 2.3.1

๐Ÿ“š Learn More

๐Ÿงช Playgrounds

๐Ÿ“š Courses

๐Ÿ† Challenges

Happy learning! ๐Ÿš€

Start
Settings