Run:
$ dnf install crun-vm
Podman will then be able to make use of the crun-vm runtime.
To also set up crun-vm for use with Docker:
-
Merge the following configuration into
/etc/docker/daemon.json
:{ "runtimes": { "crun-vm": { "path": "/usr/bin/crun-vm" } } }
-
Reload the
docker
service for the new configuration to take effect:$ service docker reload
-
Install crun-vm's runtime dependencies:
$ dnf install bash coreutils crun genisoimage grep libselinux-devel libvirt-client libvirt-daemon-driver-qemu libvirt-daemon-log openssh-clients qemu-img qemu-system-x86-core shadow-utils util-linux virtiofsd
-
Install Rust and Cargo if you do not already have Rust tooling available:
$ dnf install cargo
-
Build crun-vm:
$ cargo build
-
Copy the
target/debug/crun-vm
binary to wherever you prefer:$ cp target/debug/crun-vm /usr/local/bin/
-
If you're using Podman:
-
Merge the following configuration into
/etc/containers/containers.conf
:For rootless Podman, you can instead use
${XDG_CONFIG_PATH}/containers/containers.conf
, where$XDG_CONFIG_PATH
defaults to${HOME}/.config
.[engine.runtimes] crun-vm = ["/usr/local/bin/crun-vm"]
If you're using Docker:
-
Merge the following configuration into
/etc/docker/daemon.json
:{ "runtimes": { "crun-vm": { "path": "/usr/local/bin/crun-vm" } } }
-
Reload the
docker
service for the new configuration to take effect:$ service docker reload
-
With Podman, it is possible to use crun-vm without installing it, i.e.,
performing only steps 1–3 above. In this case, instead of setting the runtime
with --runtime crun-vm
, specify an absolute path to the runtime binary:
--runtime "$PWD"/target/debug/crun-vm
.