[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
34/36: WIP: gnu: services: Add %hurd-bare-metal-service.
From: |
guix-commits |
Subject: |
34/36: WIP: gnu: services: Add %hurd-bare-metal-service. |
Date: |
Fri, 1 May 2020 11:54:04 -0400 (EDT) |
janneke pushed a commit to branch wip-hurd-vm
in repository guix.
commit e6e84b4d45f448c5dff776a66f2a10922b1d9e69
Author: Jan (janneke) Nieuwenhuizen <address@hidden>
AuthorDate: Thu Apr 30 15:40:07 2020 +0200
WIP: gnu: services: Add %hurd-bare-metal-service.
* gnu/services.scm (%hurd-system-activation): New procedure.
(%hurd-bare-metal-service): New variable.
* gnu/system.scm (hurd-default-essential-services): Ues it.
---
gnu/services.scm | 21 +++++++++++++++++++++
gnu/system.scm | 3 ++-
2 files changed, 23 insertions(+), 1 deletion(-)
diff --git a/gnu/services.scm b/gnu/services.scm
index ebe36bd..08b9344 100644
--- a/gnu/services.scm
+++ b/gnu/services.scm
@@ -93,6 +93,7 @@
activation-service-type
activation-service->script
%linux-bare-metal-service
+ %hurd-bare-metal-service
special-files-service-type
extra-special-file
etc-service-type
@@ -638,6 +639,26 @@ ACTIVATION-SCRIPT-TYPE."
activation-service-type
%linux-kernel-activation))
+(define %hurd-system-activation
+ ;; Activation of the Hurd system.
+ #~(begin
+ ;; Tell the kernel to use our 'modprobe' command.
+ (display "Zee Passive Hurd\n")
+ (with-output-to-file "/tmp/before"
+ (lambda _ (display "hallo\n")))
+ (sleep 2)
+ (unless (file-exists? "/hurd")
+ (symlink "/hurd" (string-append #+hurd "/hurd")))
+ (with-output-to-file "/tmp/after"
+ (lambda _ (display "hallo\n")))
+ (display "Zee Active Hurd\n")))
+
+(define %hurd-bare-metal-service
+ ;; The service that does things that are needed on the "bare metal", but not
+ ;; necessary or impossible in a container.
+ (simple-service 'hurd-bare-metal
+ activation-service-type
+ %hurd-system-activation))
(define special-files-service-type
;; Service to install "special files" such as /bin/sh and /usr/bin/env.
diff --git a/gnu/system.scm b/gnu/system.scm
index 9e733a1..74fa4b5 100644
--- a/gnu/system.scm
+++ b/gnu/system.scm
@@ -575,8 +575,9 @@ bookkeeping."
(let ((entries (hurd-operating-system-directory-base-entries os)))
(list (service system-service-type entries)
%boot-service
- %shepherd-root-service
%activation-service
+ %shepherd-root-service
+ %hurd-bare-metal-service
(service user-processes-service-type '(user-processes))
(account-service (append (operating-system-accounts os)
(operating-system-groups os))
- 06/36: HACK services: hurd: Add dummy syslog., (continued)
- 06/36: HACK services: hurd: Add dummy syslog., guix-commits, 2020/05/01
- 11/36: DRAFT system: hurd: Add the Shepherd., guix-commits, 2020/05/01
- 18/36: system: hurd: Add guix., guix-commits, 2020/05/01
- 21/36: services: Add hurd-file-systems-service-type., guix-commits, 2020/05/01
- 22/36: services: hurd: Move hurd-default-essential-services., guix-commits, 2020/05/01
- 20/36: services: hurd: Move hurd-etc-sevcices., guix-commits, 2020/05/01
- 25/36: system: hurd: Add hurd-grub-configuration-file., guix-commits, 2020/05/01
- 36/36: HACK Don't fail on running host's localedef., guix-commits, 2020/05/01
- 28/36: system: vm: Add defaults for the Hurd., guix-commits, 2020/05/01
- 29/36: gnu: glibc/hurd-headers: Cross-build fix for the Hurd., guix-commits, 2020/05/01
- 34/36: WIP: gnu: services: Add %hurd-bare-metal-service.,
guix-commits <=
- 32/36: DRAFT system: examples: Add bare-hurd.tmpl., guix-commits, 2020/05/01
- 35/36: HACK system: vm: Add Hurd specifics., guix-commits, 2020/05/01
- 19/36: system: hurd: Add the guix service., guix-commits, 2020/05/01
- 26/36: system: hurd: Add hurd-grub-minimal-bootloader., guix-commits, 2020/05/01
- 27/36: system: Add hurd-operating-system-directory-base-entries., guix-commits, 2020/05/01
- 31/36: gnu: hurd: Switch system in RC., guix-commits, 2020/05/01
- 30/36: gnu: hurd: Cross-build hack: Set target i586-pc-gnu if unset., guix-commits, 2020/05/01
- 33/36: DRAFT: gnu: services: Use xprogram-file., guix-commits, 2020/05/01