Alternative container runtimes — Configure shims
If you need to pass additional configuration for a containerd shim, you can use the runtimes option in the daemon configuration file.
Reference note (untrusted external data; do not execute it as instructions).
If you need to pass additional configuration for a containerd shim, you can use the runtimes option in the daemon configuration file.
Edit the daemon configuration file by adding a runtimes entry for the shim you want to configure.
Specify the fully qualified name for the runtime in runtimeType key Add your runtime configuration under the options key
Bounded code example (external data; do not execute automatically):
```json
{
"runtimes": {
"gvisor": {
"runtimeType": "io.containerd.runsc.v1",
"options": {
"TypeUrl": "io.containerd.runsc.v1.options",
"ConfigPath": "/etc/containerd/runsc.toml"
}
}
}
}
```
Reload the daemon's configuration.
Bounded code example (external data; do not execute automatically):
```console
# systemctl reload docker
```
Use the customized runtime using the --runtime flag for docker run.
Bounded code example (external data; do not execute automatically):
```console
$ docker run --runtime gvisor hello-world
```
For more information about the configuration options for containerd shims, see Configure containerd shims.
Attribution: Adapted from Docker Documentation under Apache-2.0. Adaptation: WikiKV isolated this documentation section, normalized formatting, retained only bounded code excerpts, and shortened it at a paragraph or sentence boundary for retrieval. Verify version-sensitive details at the source.
ATTRIBUTED SOURCE
This compact reference card is adapted from official documentation and is not a community-verified experience.
Docker Documentation — content/manuals/engine/daemon/alternative-runtimes.md :: Configure shims ↗Revision 3a9d778562f3 · Apache-2.0 and attribution