From 6f2a356ca10ab97ed257097996593d707eca9bd7 Mon Sep 17 00:00:00 2001 From: Helmut Grohne Date: Sun, 6 Apr 2025 07:59:25 +0200 Subject: add a new family of wrappers for EFI based images debefivm-create is based on mmdebstrap-autopkgtest-build-qemu, which is is co-authored with Johannes Schauer Marin Rodrigues. Also thanks to Jochen Sprickerhof for suggesting the --rootsize option for use in Debusine. --- bin/debefivm-run | 401 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 401 insertions(+) create mode 100755 bin/debefivm-run (limited to 'bin/debefivm-run') diff --git a/bin/debefivm-run b/bin/debefivm-run new file mode 100755 index 0000000..c93d7d2 --- /dev/null +++ b/bin/debefivm-run @@ -0,0 +1,401 @@ +#!/bin/sh +# SPDX-FileCopyrightText: 2024-2025 Helmut Grohne +# SPDX-License-Identifier: MIT + +: <<'POD2MAN' +=head1 NAME + +debefivm-run - Run a virtual machine from an EFI-bootable raw disk image + +=head1 SYNOPSIS + +B<-debefivm-run> [B<-a>] I] [B<-i> F] [B<-s> I] [B<--> I] + +=head1 DESCRIPTION + +B is essentially a thing wrapper around B for running a virtual machine from an UEFI bootable raw disk image. +Such an image may be created using B or with another image creator, but its use is limited to architectures supporting EFI booting. + +=head1 OPTIONS + +=over 8 + +=item B<-a> I, B<--architecture>=I + +Override the Debian architecture of the provided image. +If the image uses architecture-specific type UUIDs for the root partition, the architecture can be detected. +Otherwise, the host's architecture is assumed. +The images created by B employ these UUIDs. +The value is used to determine the correct emulator binary as well as suitable EFI firmware. + +=item B<--efi-vars>=F + +EFI variables can be changed and retained across reboots of a virtual machine if a separate variable file is supplied. +The passed file is created from a template if absent. +If absent, a read-only variable store will be supplied to the virtual machine. + +=item B<-i> F, B<--image>=F + +This option specifies the location of the virtual machine image file. +By default F in the working directory is used. + +=item B<--netopt>=I