treewide: migrate to qemu-kvm in toolchain-bundle
Change-Id: I42a10a9adf7bdccb83ef997c6d554140ffaade4b
Reviewed-on: https://review.monogon.dev/c/monogon/+/4052
Reviewed-by: Jan Schär <jan@monogon.tech>
Tested-by: Jenkins CI
diff --git a/metropolis/installer/test/BUILD.bazel b/metropolis/installer/test/BUILD.bazel
index a5e8973..8aab4b4 100644
--- a/metropolis/installer/test/BUILD.bazel
+++ b/metropolis/installer/test/BUILD.bazel
@@ -7,6 +7,7 @@
srcs = ["run_test.go"],
data = [
":kernel",
+ "//build/toolchain/toolchain-bundle:qemu-kvm",
"//metropolis/installer/test/testos:testos_image",
"//third_party/edk2:OVMF_CODE.fd",
"//third_party/edk2:OVMF_VARS.fd",
@@ -18,6 +19,7 @@
"xOvmfCodePath": "$(rlocationpath //third_party/edk2:OVMF_CODE.fd )",
"xInstallerPath": "$(rlocationpath :kernel )",
"xImagePath": "$(rlocationpath //metropolis/installer/test/testos:testos_image )",
+ "xQEMUPath": "$(rlocationpath //build/toolchain/toolchain-bundle:qemu-kvm )",
},
deps = [
"//metropolis/cli/metroctl/core",
diff --git a/metropolis/installer/test/run_test.go b/metropolis/installer/test/run_test.go
index 9d9d136..3da188a 100644
--- a/metropolis/installer/test/run_test.go
+++ b/metropolis/installer/test/run_test.go
@@ -39,6 +39,7 @@
xOvmfVarsPath string
xInstallerPath string
xImagePath string
+ xQEMUPath string
)
func init() {
@@ -46,6 +47,7 @@
for _, path := range []*string{
&xOvmfCodePath, &xOvmfVarsPath,
&xInstallerPath, &xImagePath,
+ &xQEMUPath,
} {
*path, err = runfiles.Rlocation(*path)
if err != nil {
@@ -82,7 +84,7 @@
}
qemuArgs := append(defaultArgs, args...)
pf := cmd.TerminateIfFound(expectedOutput, nil)
- return cmd.RunCommand(ctx, "qemu-system-x86_64", qemuArgs, pf)
+ return cmd.RunCommand(ctx, xQEMUPath, qemuArgs, pf)
}
// runQemuWithInstaller runs the Metropolis Installer in a qemu, performing the