[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
36/36: DRAFT system: examples: Add bare-hurd.tmpl.
From: |
guix-commits |
Subject: |
36/36: DRAFT system: examples: Add bare-hurd.tmpl. |
Date: |
Mon, 27 Apr 2020 06:19:54 -0400 (EDT) |
janneke pushed a commit to branch wip-hurd-vm
in repository guix.
commit fdb35e387bea96c6a80526c712977d1fbdf931c4
Author: Jan (janneke) Nieuwenhuizen <address@hidden>
AuthorDate: Sat Apr 25 12:45:46 2020 +0200
DRAFT system: examples: Add bare-hurd.tmpl.
XXX This does not work yet. Start of migration from
./pre-inst-env guix build -f gnu/system/hurd.scm
to
./pre-inst-env guix system vm-image --target=i586-pc-gnu
gnu/system/examples/bare-hurd.tmpl
See also: <https://bugs.gnu.org/40839>; wip-disk-image.
* gnu/system/hurd.scm (hurd-grub-configuration-file): Add empty firmware,
initrd.
Use lambda to empty initrd-modules proprely.
* gnu/system/examples/bare-hurd.tmpl: New file.
* Makefile.am (EXAMPLES): Add it.
---
Makefile.am | 1 +
gnu/system.scm | 6 ++----
gnu/system/examples/bare-hurd.tmpl | 29 +++++++++++++++++++++++++++++
gnu/system/hurd.scm | 32 +++++++++++++++++++++++---------
4 files changed, 55 insertions(+), 13 deletions(-)
diff --git a/Makefile.am b/Makefile.am
index bb243fe..869f32b 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -343,6 +343,7 @@ AUX_FILES = \
EXAMPLES = \
gnu/system/examples/asus-c201.tmpl \
gnu/system/examples/bare-bones.tmpl \
+ gnu/system/examples/bare-hurd.tmpl \
gnu/system/examples/beaglebone-black.tmpl \
gnu/system/examples/desktop.tmpl \
gnu/system/examples/lightweight-desktop.tmpl \
diff --git a/gnu/system.scm b/gnu/system.scm
index 60dc882..d20c83e 100644
--- a/gnu/system.scm
+++ b/gnu/system.scm
@@ -519,10 +519,8 @@ value of the SYSTEM-SERVICE-TYPE service."
(define* (hurd-operating-system-directory-base-entries os)
"Return the basic entries of the 'system' directory of OS for use as the
value of the SYSTEM-SERVICE-TYPE service."
- (let ((locale (operating-system-locale-directory os)))
- (mlet* %store-monad ((kernel -> (operating-system-kernel os)))
- (return `(("kernel" ,kernel)
- ("locale" ,locale))))))
+ (mlet* %store-monad ()
+ (return `())))
(define (operating-system-default-essential-services os)
"Return the list of essential services for OS. These are special services
diff --git a/gnu/system/examples/bare-hurd.tmpl
b/gnu/system/examples/bare-hurd.tmpl
new file mode 100644
index 0000000..263ad53
--- /dev/null
+++ b/gnu/system/examples/bare-hurd.tmpl
@@ -0,0 +1,29 @@
+;; -*-scheme-*-
+
+;; This is an operating system configuration template
+;; for a "bare bones" setup, with no X11 display server.
+
+(use-modules (gnu) (gnu system hurd))
+(use-service-modules hurd ssh)
+(use-package-modules ssh)
+
+(define %hurd-os
+ (operating-system
+ (inherit %hurd-default-operating-system)
+ (bootloader (bootloader-configuration
+ (bootloader hurd-grub-minimal-bootloader)
+ (target "/dev/sdX")))
+ (host-name "guixygnu")
+ (timezone "GNUrope")
+ (packages %base-packages/hurd)
+ (services (cons (service openssh-service-type
+ (openssh-configuration
+ (use-pam? #f)
+ (openssh openssh)
+ (port-number 2222)
+ (permit-root-login #t)
+ (allow-empty-passwords? #t)
+ (password-authentication? #t)))
+ %base-services/hurd))))
+
+%hurd-os
diff --git a/gnu/system/hurd.scm b/gnu/system/hurd.scm
index 0054c77..aa29faf 100644
--- a/gnu/system/hurd.scm
+++ b/gnu/system/hurd.scm
@@ -104,15 +104,15 @@
(define* (hurd-grub-configuration-file config entries
#:key
- (system (%current-system))
+ (system "i586-pc-gnu")
(old-entries '()))
- (let ((hurd (if (equal? system (%current-system))
+ (let ((hurd (if (equal? (%current-system) "i586-pc-gnu")
hurd
(with-parameters ((%current-target-system system))
hurd)))
(mach (with-parameters ((%current-system "i686-linux"))
gnumach))
- (libc (if (equal? system (%current-system))
+ (libc (if (equal? system "i586-pc-gnu")
glibc
(cross-libc system))))
(computed-file "grub.cfg"
@@ -142,15 +142,30 @@ menuentry \"GNU\" {
(define %hurd-default-operating-system
(operating-system
- (host-name "guixygnu")
+ (kernel hurd)
+ ;; (kernel-loadable-modules '())
+ (kernel-arguments '())
(bootloader (bootloader-configuration
(bootloader hurd-grub-minimal-bootloader)
(target "/dev/vda")))
- (kernel hurd)
- (initrd-modules '())
+ (label (lambda _ "label"))
+ (initrd (lambda _ '()))
+ (initrd-modules (lambda _ '()))
+ (firmware '())
+ (host-name "guixygnu")
+ ;; (hosts-file #F)
+ ;; (mapped-devices '())
(file-systems '())
- (swap-devices '())
+ ;; (swap-devices '())
+ (users '())
+ ;(groups '())
+ (skeletons '())
+ ;; (issue %default-issue)
+ (packages %base-packages/hurd)
(timezone "GNUrope")
+ ;; (locale "en_US.utf8")
+ (locale-definitions '())
+ ;; (locale-libcs '())
(name-service-switch #f)
(essential-services (hurd-default-essential-services
this-operating-system))
(services (cons (service openssh-service-type
@@ -162,10 +177,9 @@ menuentry \"GNU\" {
(allow-empty-passwords? #t)
(password-authentication? #t)))
%base-services/hurd))
- (packages %base-packages/hurd)
(pam-services '())
(setuid-programs '())
- (users '())))
+ (sudoers-file #f)))
(define (input->packages input)
"Return the list of packages in INPUT."
- 32/36: system: hurd: Add hurd-grub-configuration-file., (continued)
- 32/36: system: hurd: Add hurd-grub-configuration-file., guix-commits, 2020/04/27
- 33/36: system: hurd: Add hurd-grub-minimal-bootloader., guix-commits, 2020/04/27
- 23/36: system: hurd: Create system profile for guix development., guix-commits, 2020/04/27
- 30/36: system: hurd: Export system variables., guix-commits, 2020/04/27
- 27/36: services: hurd: Move hurd-etc-sevcices., guix-commits, 2020/04/27
- 09/36: gnu: Add libtirpc/hurd., guix-commits, 2020/04/27
- 31/36: services: hurd: Use hurd-file-systems-service., guix-commits, 2020/04/27
- 35/36: system: vm: Add defaults for the Hurd., guix-commits, 2020/04/27
- 24/36: system: gnu: Add %bootstrap-{gcc, binutils, glibc} for devel profile., guix-commits, 2020/04/27
- 34/36: system: Add hurd-operating-system-directory-base-entries., guix-commits, 2020/04/27
- 36/36: DRAFT system: examples: Add bare-hurd.tmpl.,
guix-commits <=
- 26/36: system: hurd: Add the guix service., guix-commits, 2020/04/27