guix-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

23/35: system: examples: Add bare-hurd64.tmpl.


From: guix-commits
Subject: 23/35: system: examples: Add bare-hurd64.tmpl.
Date: Tue, 3 Dec 2024 02:45:51 -0500 (EST)

janneke pushed a commit to branch master
in repository guix.

commit 9e2eae54f9ae06a1ca5873ab81fa4835683db2b9
Author: Janneke Nieuwenhuizen <janneke@gnu.org>
AuthorDate: Tue Nov 12 08:05:52 2024 +0100

    system: examples: Add bare-hurd64.tmpl.
    
    * gnu/system/examples/bare-hurd.tmpl: Update comments.
    * gnu/system/examples/bare-hurd64.tmpl: New file.
    
    Change-Id: I8d26afd19afaa8fb3558948b50b0efdc0f83f29c
---
 gnu/system/examples/bare-hurd.tmpl                 | 21 ++++++++------
 .../examples/{bare-hurd.tmpl => bare-hurd64.tmpl}  | 33 +++++++++++++---------
 2 files changed, 31 insertions(+), 23 deletions(-)

diff --git a/gnu/system/examples/bare-hurd.tmpl 
b/gnu/system/examples/bare-hurd.tmpl
index 68c6d3c166..9bfa776769 100644
--- a/gnu/system/examples/bare-hurd.tmpl
+++ b/gnu/system/examples/bare-hurd.tmpl
@@ -3,23 +3,26 @@
 ;; This is an operating system configuration template
 ;; for a "bare bones" QEMU setup, with no X11 display server.
 
-;; To build a disk image for a virtual machine, do
+;; To build a disk image for a virtual machine, do:
 ;;
-;;     ./pre-inst-env guix system image --image-type=hurd-raw \
+;;     ./pre-inst-env guix system image --image-type=hurd-qcow2 \
 ;;         gnu/system/examples/bare-hurd.tmpl
 ;;
-;; You may run it like so
+;; You may run it like so:
 ;;
-;;     guix shell qemu -- qemu-system-i386 -enable-kvm -m 2048 \
-;;      -device rtl8139,netdev=net0 -netdev 
user,id=net0,hostfwd=tcp:127.0.0.1:10022-:2222 \
-;;      -snapshot -hda <the-image>
+;;     guix shell qemu -- qemu-system-i386 -m 2048                \
+;;       --enable-kvm                                             \
+;;       --device e1000,netdev=net0                               \
+;;       --netdev user,id=net0,hostfwd=tcp:127.0.0.1:10022-:2222  \
+;;       --snapshot
+;;       --hda /gnu/store/...-disk-image
 ;;
-;; and use it like
+;; and use it like:
 ;;
 ;;     ssh -p 10022 root@localhost
 ;;     guix build -e '(@@ (gnu packages commencement) gnu-make-boot0)'
 ;;
-;; or even (if you use --image-size=3G)
+;; or even, if you build the image with at least --image-size=3G:
 ;;
 ;;     guix build hello
 
@@ -34,7 +37,7 @@
                  (bootloader grub-minimal-bootloader)
                  (targets '("/dev/sdX"))))
     (file-systems (cons (file-system
-                          (device (file-system-label "my-root"))
+                          (device (file-system-label "hurd"))
                           (mount-point "/")
                           (type "ext2"))
                         %base-file-systems))
diff --git a/gnu/system/examples/bare-hurd.tmpl 
b/gnu/system/examples/bare-hurd64.tmpl
similarity index 66%
copy from gnu/system/examples/bare-hurd.tmpl
copy to gnu/system/examples/bare-hurd64.tmpl
index 68c6d3c166..89811e458a 100644
--- a/gnu/system/examples/bare-hurd.tmpl
+++ b/gnu/system/examples/bare-hurd64.tmpl
@@ -3,23 +3,27 @@
 ;; This is an operating system configuration template
 ;; for a "bare bones" QEMU setup, with no X11 display server.
 
-;; To build a disk image for a virtual machine, do
+;; To build a disk image for a virtual machine, do:
 ;;
-;;     ./pre-inst-env guix system image --image-type=hurd-raw \
-;;         gnu/system/examples/bare-hurd.tmpl
+;;     ./pre-inst-env guix system image --image-type=hurd64-qcow2 \
+;;         gnu/system/examples/bare-hurd64.tmpl
 ;;
-;; You may run it like so
+;; You may run it like so:
 ;;
-;;     guix shell qemu -- qemu-system-i386 -enable-kvm -m 2048 \
-;;      -device rtl8139,netdev=net0 -netdev 
user,id=net0,hostfwd=tcp:127.0.0.1:10022-:2222 \
-;;      -snapshot -hda <the-image>
+;;     guix shell qemu@7 -- qemu-system-x86_64 -m 2048            \
+;;       --machine q35                                            \
+;;       --enable-kvm                                             \
+;;       --device e1000,netdev=net0                               \
+;;       --netdev user,id=net0,hostfwd=tcp:127.0.0.1:10022-:2222  \
+;;       --snapshot
+;;       --hda /gnu/store/...-disk-image
 ;;
-;; and use it like
+;; and use it like:
 ;;
 ;;     ssh -p 10022 root@localhost
 ;;     guix build -e '(@@ (gnu packages commencement) gnu-make-boot0)'
 ;;
-;; or even (if you use --image-size=3G)
+;; or even, if you build the image with at least --image-size=3G:
 ;;
 ;;     guix build hello
 
@@ -27,18 +31,19 @@
 (use-service-modules ssh)
 (use-package-modules ssh)
 
-(define %hurd-os
+(define %hurd64-os
   (operating-system
-    (inherit %hurd-default-operating-system)
+    (inherit %hurd64-default-operating-system)
     (bootloader (bootloader-configuration
                  (bootloader grub-minimal-bootloader)
                  (targets '("/dev/sdX"))))
+    (kernel-arguments '("noide")) ;use rumpdisk
     (file-systems (cons (file-system
-                          (device (file-system-label "my-root"))
+                          (device (file-system-label "hurd"))
                           (mount-point "/")
                           (type "ext2"))
                         %base-file-systems))
-    (host-name "guixygnu")
+    (host-name "guixygnu64")
     (timezone "Europe/Amsterdam")
     (users (cons (user-account
                   (name "guix")
@@ -62,4 +67,4 @@
                     ;; %base-services/hurd
                     %base-services+qemu-networking/hurd))))
 
-%hurd-os
+%hurd64-os



reply via email to

[Prev in Thread] Current Thread [Next in Thread]