[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
02/04: HACK gnu: hurd: Support system vm-image activation.
From: |
guix-commits |
Subject: |
02/04: HACK gnu: hurd: Support system vm-image activation. |
Date: |
Sat, 2 May 2020 05:40:16 -0400 (EDT) |
janneke pushed a commit to branch wip-hurd-vm
in repository guix.
commit c01cf28bd46be73002218f8c9424930866250d5a
Author: Jan (janneke) Nieuwenhuizen <address@hidden>
AuthorDate: Sat May 2 11:02:36 2020 +0200
HACK gnu: hurd: Support system vm-image activation.
* gnu/packages/hurd.scm (hurd-rc-script): Find shepherd.conf in the store.
---
gnu/packages/hurd.scm | 11 ++++++++---
1 file changed, 8 insertions(+), 3 deletions(-)
diff --git a/gnu/packages/hurd.scm b/gnu/packages/hurd.scm
index 378547a..5dd386d 100644
--- a/gnu/packages/hurd.scm
+++ b/gnu/packages/hurd.scm
@@ -367,9 +367,14 @@ boot, since this cannot be done from GNU/Linux."
(format #t "Activating system...\n")
(invoke "/run/current-system/profile/bin/sh" "/boot/activation")
;; Hand over to the Shepherd
- (false-if-exception (delete-file "/var/run/shepherd/socket"))
- (invoke "/run/current-system/profile/bin/shepherd"
- "--config" "/etc/shepherd.conf"))))
+ (let ((shepherd.conf
+ (if (file-exists? "/etc/shepherd.conf")
+ "/etc/shepherd.conf"
+ (car (find-files "/gnu/store" ".*-shepherd.conf")))))
+ (false-if-exception (delete-file "/var/run/shepherd/socket"))
+ (format #t "Starting the Shepherd... ~a\n" shepherd.conf)
+ (invoke "/run/current-system/profile/bin/shepherd"
+ "--config" shepherd.conf)))))
;; FIXME: We want the program to use the cross-compiled Guile when
;; cross-compiling. But why do we need to be explicit here?