talira

CLI tool for spawning and running containers according to the OCI specification

open sourceApache-2.0self-hostablefree

runc is the Open Container Initiative's command-line tool for spawning and running containers on Linux according to the OCI Runtime Specification: it takes an OCI bundle (a root filesystem and a config.json, which runc spec writes as a template) and creates, starts, kills and deletes the container. It's a low-level runtime that higher-level software calls, the default runtime of containerd among others, and its README recommends Docker or Podman unless something rules them out. It supports rootless containers, cgroup v1 and v2 with the systemd cgroup driver, seccomp syscall filtering, AppArmor and SELinux, and checkpoint and restore through CRIU. Releases are signed, Cure53 audited it, and it's Apache-2.0, written in Go.

Ways to install

Problems it solves

  • start a container on Linux straight from an OCI bundle without Docker or a daemon
  • the low-level OCI runtime that containerd and other engines use to actually create containers
  • run a container as an unprivileged user with no root access
  • checkpoint a running container and restore it later or on another host
  • generate a template OCI runtime config.json and edit it by hand
  • apply seccomp syscall filters and cgroup limits to a process I run in a container
  • a container runtime to embed in a custom container engine or orchestrator
  • use the systemd cgroup driver for containers on a cgroup v2 host

Features

  • implements the OCI Runtime Specification
  • runs containers from an OCI bundle: a root filesystem plus config.json
  • runc spec writes a template config; --rootless writes one for unprivileged users
  • create, start, state, kill and delete lifecycle commands, or run for all of them
  • rootless containers
  • cgroup v1 and v2, including the systemd cgroup driver
  • seccomp syscall filtering through libseccomp (a default build tag)
  • AppArmor and SELinux support always built in
  • checkpoint and restore through CRIU
  • optional libpathrs for path safety
View 1 more
  • releases signed with keys in the repository's runc.keyring; third-party security audit by Cure53

Limitations

  • Doesn't run on macOS or Windows: runc only supports Linux3

Capabilities

Has a command line toolplan not known

Alternatives

The same job

These do what runc does.

  1. youki A container runtime written in Rust
  2. crun A fast and lightweight fully featured OCI runtime and C library for running containers
  3. gVisor Application Kernel for Containers
  4. Kata Containers The speed of containers, the security of VMs
  5. containerd An industry-standard container runtime with an emphasis on simplicity, robustness and portability
  6. CRI-O Lightweight Container Runtime for Kubernetes

Compare runc with the top 3