vmexec-run(1)
β¨ NAME β¨
okay so bestie, you're on the vmexec-run(1) page in the General Commands Manual, and it's literally about one thing: run a command in a new virtual machine π
β¨
π¦ SYNOPSIS π¦
vmexec run [-d|--detach] [--rm] [--vmid] [--disable-kvm] [-m|--memory]
[-e|--env] [-w|--workdir] [-v|--volume] [--pmem] [-p|--publish]
[-s|--ssh-timeout] [-i|--interactive] [-t|--tty] [--show-vm-window]
[--pull] [-h|--help] <IMAGE_SOURCE> [ARGS]
πΈ DESCRIPTION πΈ
Run a command in a new virtual machine. that's the whole vibe, no cap π«Ά
π OPTIONS π
-d,--detachβ run the virtual machine in the background and print the virtual machine ID π--rmβ remove the virtual machine runtime data after exit π§Ή--vmid <VMID>β virtual machine identifier. If you don't provide one, a random identifier will be generated β¨--disable-kvmβ run the virtual machine with TCG instead of KVM. This is mostly useful in environments where KVM is not available. it's gonna be a lot slower, but it might be acceptable in some contexts π-m,--memory <MEMORY>β memory limit for the virtual machine in GBs. Must be an integer of at least1. If not provided, all available host memory is used. this mimics the behavior of a normal process outside a virtual machine π-e,--env <ENV>β set environment variables for the process inside the virtual machine. Can be provided multiple times. Expected format:KEY=VALUEπ-w,--workdir <WORKDIR>β working directory inside the virtual machine. The default working directory for running binaries within a virtual machine is dependent on the image. most commonly, it'll be/rootπ-v,--volume <VOLUMES>β bind mount a volume into the virtual machine. The source may be a directory or a single file. Can be provided multiple times. Expected format:source:dest[:ro]rocan optionally be provided to mark the mount as read-only. Example:$PWD/src:/mnt:roπ₯--pmem <PMEMS>β mount a virtio-pmem device file into the virtual machine. You might want to do this to bypass the guest page cache. This is important if you're overprovisioning your host (i.e. giving VMs more combined memory than the host actually has) and have a write-heavy workload. For more info, see:https://www.qemu.org/docs/master/system/devices/virtio-pmem.htmlCan be provided multiple times. Specified as an absolute path inside the VM where the device will be mounted as an ext4 filesystem, and the maximum size in gigabytes. On the host, this will show up as a file inside the VM's state dir. Expected format:dest:<size>Example:/var/lib:20πΎ-p,--publish <PUBLISHED_PORTS>β publish a port on the virtual machine to the host. Can be provided multiple times. Expected format:[[hostip:][hostport]:]vmporthostipis optional and if not provided, the port will be bound on all host IPs.hostportis optional and if not provided, the same value ofvmportwill be used for the host port. Currently only IPv4 is supported forhostipπ-s,--ssh-timeout <SSH_TIMEOUT> [default: 20]β SSH connection timeout. Try for this long (in seconds) to connect to the virtual machine's SSH server β³-i,--interactive <INTERACTIVE> [default: auto]β makeSTDINavailable to the virtual machine's process. If'auto', this will try to read from stdin if it is available, and do nothing when stdin is not available. If'always', this will try to read from stdin and abort when stdin is not available. Possible values:alwaysβ forward stdin and fail if it can't be openedneverβ don't forward stdinautoβ forward stdin if it can be opened, otherwise carry on without it π«Ά
-t,--tty <TTY> [default: auto]β allocate a pseudo-TTY for the virtual machine. If'auto', this will be enabled in casevmexecis run from an interactive terminal. Possible values:alwaysβ allocate a pseudo-TTYneverβ don't allocate a pseudo-TTYautoβ allocate a pseudo-TTY if stdout is a terminal π₯οΈ
--show-vm-windowβ show a QEMU window with the virtual machine running in it. This is mostly useful for debugging boot failures π--pull <PULL> [default: missing]β when to pull a new image. Possible values:missingβ use the newest local image and only download one if there is noneneverβ use the newest local image and fail if there is nonenewerβ check for a newer image and download it if there is one π
-h,--helpβ Print help (see a summary with '-h') β¨<IMAGE_SOURCE>β either an operating system (e.g.archlinux) or a path to an image. Possible OS types:archlinuxπ§[ARGS]β Arguments to run in the virtual machine π
π cute sign-off: source/versionrun, manualvmexec-run(1), and the date wasn't printed in the original footerβso I'm not inventing one, bestie β¨π
π¦ where this page comes from
- arch rolling: vmexec 0.8.0-1 Β· MIT
- arch rolling: vmexec 0.8.1-1 Β· MIT
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms