[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[bug#43650] [PATCH 4/8] services: hurd-vm: Check whether /dev/kvm exists
From: |
Ludovic Courtès |
Subject: |
[bug#43650] [PATCH 4/8] services: hurd-vm: Check whether /dev/kvm exists at run time. |
Date: |
Sun, 27 Sep 2020 17:32:17 +0200 |
This change allows a childhurd to run within Guix System in a VM.
* gnu/services/virtualization.scm (hurd-vm-shepherd-service)[vm-command]:
Stage the 'file-exists?' call.
---
gnu/services/virtualization.scm | 15 ++++++++-------
1 file changed, 8 insertions(+), 7 deletions(-)
diff --git a/gnu/services/virtualization.scm b/gnu/services/virtualization.scm
index d184eea746..b84203ad18 100644
--- a/gnu/services/virtualization.scm
+++ b/gnu/services/virtualization.scm
@@ -937,13 +937,14 @@ is added to the OS specified in CONFIG."
(provisions '(hurd-vm childhurd)))
(define vm-command
- #~(list
- (string-append #$qemu "/bin/qemu-system-i386")
- #$@(if (file-exists? "/dev/kvm") '("--enable-kvm") '())
- "-m" (number->string #$memory-size)
- #$@net-options
- #$@options
- "--hda" #+image))
+ #~(append (list #$(file-append qemu "/bin/qemu-system-i386")
+ "-m" (number->string #$memory-size)
+ #$@net-options
+ #$@options
+ "--hda" #+image)
+ (if (file-exists? "/dev/kvm")
+ '("--enable-kvm")
+ '())))
(list
(shepherd-service
--
2.28.0
[bug#43650] [PATCH 5/8] services: guix: Generate key pair if needed during activation., Ludovic Courtès, 2020/09/27
[bug#43650] [PATCH 6/8] services: hurd-vm: Initialize the guest's SSH/Guix keys at activation time., Ludovic Courtès, 2020/09/27
[bug#43650] [PATCH 7/8] services: hurd-vm: Pass "-no-reboot" when spawning the Hurd VM., Ludovic Courtès, 2020/09/27
[bug#43650] [PATCH 8/8] secret-service: Add a timeout when waiting for a client., Ludovic Courtès, 2020/09/27
[bug#43650] [PATCH 1/8] services: hurd-vm: Run QEMU as an unprivileged user., Jan Nieuwenhuizen, 2020/09/28