@@ -1,7 +1,7 @@
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2017 Ryan Moe <ryan.moe@gmail.com>
;;; Copyright © 2018, 2020-2024 Ludovic Courtès <ludo@gnu.org>
-;;; Copyright © 2020, 2021, 2023 Janneke Nieuwenhuizen <janneke@gnu.org>
+;;; Copyright © 2020, 2021, 2023, 2024 Janneke Nieuwenhuizen <janneke@gnu.org>
;;; Copyright © 2021 Timotej Lazar <timotej.lazar@araneo.si>
;;; Copyright © 2022 Oleg Pykhalov <go.wigust@gmail.com>
;;; Copyright © 2022 Leo Nikkilä <hello@lnikki.la>
@@ -1643,7 +1643,7 @@ (define %hurd-vm-operating-system
;; /etc/guix/acl file in the childhurd. Thus, clear
;; 'authorize-key?' so that it's not overridden at activation
;; time.
- (modify-services %base-services/hurd
+ (modify-services %base-services+qemu-networking/hurd
(guix-service-type config =>
(guix-configuration
(inherit config)
@@ -1,7 +1,7 @@
;; -*-scheme-*-
;; This is an operating system configuration template
-;; for a "bare bones" setup, with no X11 display server.
+;; for a "bare bones" QEMU setup, with no X11 display server.
;; To build a disk image for a virtual machine, do
;;
@@ -54,6 +54,12 @@
(permit-root-login #t)
(allow-empty-passwords? #t)
(password-authentication? #t)))
- %base-services/hurd))))
+ ;; For installing on a real (non-QEMU) machine, use:
+ ;; (static-networking-service-type
+ ;; (list %loopback-static-networking
+ ;; (static-networking
+ ;; ...)))
+ ;; %base-services/hurd
+ %base-services+qemu-networking/hurd))))
%hurd-os
@@ -1,6 +1,6 @@
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2020-2024 Ludovic Courtès <ludo@gnu.org>
-;;; Copyright © 2020, 2023 Janneke Nieuwenhuizen <janneke@gnu.org>
+;;; Copyright © 2020, 2023, 2024 Janneke Nieuwenhuizen <janneke@gnu.org>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -47,6 +47,7 @@ (define-module (gnu system hurd)
#:use-module (gnu system vm)
#:export (%base-packages/hurd
%base-services/hurd
+ %base-services+qemu-networking/hurd
%hurd-default-operating-system
%hurd-default-operating-system-kernel
%setuid-programs/hurd))
@@ -79,14 +80,6 @@ (define %base-packages/hurd
(define %base-services/hurd
(append (list (service hurd-console-service-type
(hurd-console-configuration (hurd hurd)))
- (service static-networking-service-type
- (list %loopback-static-networking
-
- ;; QEMU user-mode networking. To get "eth0", you need
- ;; QEMU to emulate a device for which Mach has an
- ;; in-kernel driver, for instance with:
- ;; --device rtl8139,netdev=net0 --netdev user,id=net0
- %qemu-static-networking))
(service guix-service-type
(guix-configuration
(extra-options '("--disable-chroot"
@@ -102,6 +95,18 @@ (define %base-services/hurd
(tty (string-append "tty" (number->string n))))))
(iota 6 1))))
+(define %base-services+qemu-networking/hurd
+ (cons
+ (service static-networking-service-type
+ (list %loopback-static-networking
+
+ ;; QEMU user-mode networking. To get "eth0", you need
+ ;; QEMU to emulate a device for which Mach has an
+ ;; in-kernel driver, for instance with:
+ ;; --device rtl8139,netdev=net0 --netdev user,id=net0
+ %qemu-static-networking))
+ %base-services/hurd))
+
(define %setuid-programs/hurd
;; Default set of setuid-root programs.
(map file-like->setuid-program
@@ -60,7 +60,7 @@ (define hurd-barebones-os
(permit-root-login #t)
(allow-empty-passwords? #t)
(password-authentication? #t)))
- %base-services/hurd))))
+ %base-services+qemu-networking/hurd))))
(define hurd-initialize-root-partition
#~(lambda* (#:rest args)