summaryrefslogtreecommitdiffhomepage
path: root/g3doc/user_guide/containerd
diff options
context:
space:
mode:
authorIan Lewis <ianlewis@google.com>2021-04-28 16:18:21 -0700
committergVisor bot <gvisor-bot@google.com>2021-04-28 16:28:46 -0700
commit39fdf0b950e2161247b60d8576151c6015a3b47c (patch)
tree1a8cb21f0c3d3d6e22ae8b898882128572d617a0 /g3doc/user_guide/containerd
parente1149179f3d5d7cbacb160d5bee6b00fe64a08ae (diff)
Use containerd v2 config format in docs
Fixes #5170 PiperOrigin-RevId: 371007691
Diffstat (limited to 'g3doc/user_guide/containerd')
-rw-r--r--g3doc/user_guide/containerd/configuration.md20
-rw-r--r--g3doc/user_guide/containerd/quick_start.md8
2 files changed, 18 insertions, 10 deletions
diff --git a/g3doc/user_guide/containerd/configuration.md b/g3doc/user_guide/containerd/configuration.md
index 011af3b10..a214fb0c7 100644
--- a/g3doc/user_guide/containerd/configuration.md
+++ b/g3doc/user_guide/containerd/configuration.md
@@ -14,6 +14,7 @@ cat <<EOF | sudo tee /etc/containerd/runsc.toml
option = "value"
[runsc_config]
flag = "value"
+EOF
```
The set of options that can be configured can be found in
@@ -32,10 +33,12 @@ configuration. Here is an example:
```shell
cat <<EOF | sudo tee /etc/containerd/config.toml
-disabled_plugins = ["restart"]
-[plugins.cri.containerd.runtimes.runsc]
+version = 2
+[plugins."io.containerd.grpc.v1.cri".containerd.runtimes.runc]
+ runtime_type = "io.containerd.runc.v2"
+[plugins."io.containerd.grpc.v1.cri".containerd.runtimes.runsc]
runtime_type = "io.containerd.runsc.v1"
-[plugins.cri.containerd.runtimes.runsc.options]
+[plugins."io.containerd.grpc.v1.cri".containerd.runtimes.runsc.options]
TypeUrl = "io.containerd.runsc.v1.options"
ConfigPath = "/etc/containerd/runsc.toml"
EOF
@@ -56,14 +59,16 @@ a containerd configuration file that enables both options:
```shell
cat <<EOF | sudo tee /etc/containerd/config.toml
-disabled_plugins = ["restart"]
+version = 2
[debug]
level = "debug"
-[plugins.linux]
+[plugins."io.containerd.runtime.v1.linux"]
shim_debug = true
-[plugins.cri.containerd.runtimes.runsc]
+[plugins."io.containerd.grpc.v1.cri".containerd.runtimes.runc]
+ runtime_type = "io.containerd.runc.v2"
+[plugins."io.containerd.grpc.v1.cri".containerd.runtimes.runsc]
runtime_type = "io.containerd.runsc.v1"
-[plugins.cri.containerd.runtimes.runsc.options]
+[plugins."io.containerd.grpc.v1.cri".containerd.runtimes.runsc.option]
TypeUrl = "io.containerd.runsc.v1.options"
ConfigPath = "/etc/containerd/runsc.toml"
EOF
@@ -93,4 +98,5 @@ log_level = "debug"
[runsc_config]
debug = "true"
debug-log = "/var/log/runsc/%ID%/gvisor.%COMMAND%.log"
+EOF
```
diff --git a/g3doc/user_guide/containerd/quick_start.md b/g3doc/user_guide/containerd/quick_start.md
index 02e82eb32..c742f225c 100644
--- a/g3doc/user_guide/containerd/quick_start.md
+++ b/g3doc/user_guide/containerd/quick_start.md
@@ -21,10 +21,12 @@ Update `/etc/containerd/config.toml`. Make sure `containerd-shim-runsc-v1` is in
```shell
cat <<EOF | sudo tee /etc/containerd/config.toml
-disabled_plugins = ["restart"]
-[plugins.linux]
+version = 2
+[plugins."io.containerd.runtime.v1.linux"]
shim_debug = true
-[plugins.cri.containerd.runtimes.runsc]
+[plugins."io.containerd.grpc.v1.cri".containerd.runtimes.runc]
+ runtime_type = "io.containerd.runc.v2"
+[plugins."io.containerd.grpc.v1.cri".containerd.runtimes.runsc]
runtime_type = "io.containerd.runsc.v1"
EOF
```