DEBEFIVM-CREATE(1)

NAME
debefivm-create - Create an EFI-bootable VM image for various Debian releases and architectures

SYNOPSIS
debefivm-create [-h hostname] [-k sshkey] [-o output] [-r release] [-s <task>] [-z size] [-- mmdebstrap options]

DESCRIPTION
Create an EFI-bootable disk image image booting into Debian. This essentially is a thin wrapper around mmdebstrap much like debvm-create. The resulting image contains a GPT partition table with an EFI system partition. A Unified Kernel Image is constructed from the installed kernel and initrd and placed into said partition. As a result, such an image may be booted with a variety of virtual machine emulators such as incus, libvirt or VirtualBox. It may also be booted using debefivm-run. No user account is created and root can login without specifying a password.

OPTIONS

-a architecture, --architecture=architecture
    Set the architecture of the virtual machine. This option is forwarded to mmdebstrap and multiple architectures may be supplied. The first architecture is used to assemble the Unified Kernel Image. It defaults to the native architecture of the installation.

-h hostname, --hostname=hostname
    Set the hostname of the virtual machine. By default, the hostname is testvm.

-k sshkey, --sshkey=sshkey
    Install the given ssh public key file into the virtual machine image for the root user. This option also causes the ssh server to be installed. By default, no key or server is installed. To connect to the vm, pass a port number to debefivm-run with the -s option.

-o output, --output=output
    Specify the file name of the resulting virtual machine image. By default, it is written to vm.img.

-r release, --release=release
    Use the given Debian release. By default, unstable is being used. If you pass a complete sources.list that includes release names to mmdebstrap, you may pass an empty string here.

-s task, --skip=task
    Skip a particular task or feature. The option may be specified multiple times or list multiple tasks to be skipped by separating them with a comma. By default, no tasks are skipped. The following tasks may be skipped.

    autologin
        Do not setup the machine for automatic password-less root login on the console. This comprises the following changes that would normally be performed. Automatic root login is configured for the init systems finit, runit, systemd and sysv. Forwarding of the "TERM" kernel command line to agetty is configured. The root password is deleted such that a login does not ask for it and the system directly boots to a shell prompt.

    kernel
        skips installing a linux kernel image. This can be useful to install a kernel without a package. If a kernel is installed via mmdebstrap option "--include", automatic kernel installation is automatically skipped.

    packagelists
        reduces the package lists inside the image. The available database for dpkg is not created. The package lists used by apt are deleted. This generally produces a smaller image, but you need to run apt update before installing packages and dpkg --set-selections does not work.

    systemdnetwork
        skips installing libnss-resolve as well as automatic network configuration via systemd-networkd.

    usrmerge
        By default debefivm-create adds a hook to enable merged-/usr without the usrmerge package given a sufficiently recent Debian release. Without the hook, dependencies will pull the usrmerge package as needed, which may result in a larger installation.

--rootsize=size
    This option may be used as an alternative to --imagesize to determine the size of the output image. It is also composed of an integer with optional unit. Unlike --imagesize it determines the size of the root filesystem partition and the resulting image will be slightly larger than the size given here.

-z size, --imagesize=size
    Specify the total image size as an integer and optional unit (example: 10K is 10*1024). Units are K,M,G,T (powers of 1024). The disk image contains an EFI system partition and an ext4 root filesystem. The EFI partition has a static size of about 128MB and the remaining space will be allocated to the root filesystem. The default is 10 GB.

-- mmdebstrap options
    All options beyond a double dash are passed to mmdebstrap after the suite and target specification. This can be used to provide additional hooks for image customization. You can also request additional packages to be installed into the image using mmdebstrap's --include option. Any positional arguments passed here will be treated as mirror specifications by mmdebstrap. The --architecture option should not be given here as debefivm-create needs to know its value to construct a Unified Kernel Image.

EXAMPLES
Create an image suitable for use with autopkgtest-virt-qemu --efi.

    debefivm-create ... -- --include=linux-image-generic,libpam-systemd,passwd,python3 --hook-dir=/usr/share/mmdebstrap/hooks/useradd --customize-hook=/usr/share/autopkgtest/setup-commands/setup-testbed

SEE ALSO
    debefivm-run(1) debefivm-ukify(1) debvm-create(1) mmdebstrap(1)