From daa6c67fb445b71f4cac4c7857f6a988f1aba79a Mon Sep 17 00:00:00 2001 From: Christopher Baines Date: Mon, 29 Nov 2021 21:01:26 +0000 Subject: gnu: guix-build-coordinator: Update to 0-40.226ec0f. * gnu/packages/package-management.scm (guix-build-coordinator): Update to 0-40.226ec0f. * doc/guix.texi (Guix Build Coordinator): Remove note about the service being considered experimental, it's been stable for a while now. --- doc/guix.texi | 6 ------ 1 file changed, 6 deletions(-) (limited to 'doc') diff --git a/doc/guix.texi b/doc/guix.texi index 2a166e3a89..09553ab2f3 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -32456,12 +32456,6 @@ running an @dfn{agent}. The build daemon is still used to build the derivations, but the Guix Build Coordinator manages allocating builds and working with the results. -@quotation Note -This service is considered experimental. Configuration options may be -changed in a backwards-incompatible manner, and not all features have -been thorougly tested. -@end quotation - The Guix Build Coordinator consists of one @dfn{coordinator}, and one or more connected @dfn{agent} processes. The coordinator process handles clients submitting builds, and allocating builds to agents. The agent -- cgit v1.2.3 From 4c5f970e8a2b946d9ae9f45631781ae3e1dc34dd Mon Sep 17 00:00:00 2001 From: Josselin Poiret Date: Mon, 15 Nov 2021 20:53:40 +0000 Subject: doc: Document LUKS2 GRUB support and shortcomings MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * doc/guix.texi (Keyboard Layout, Networking, and Partitioning)[Disk Partitioning]: Document it. Signed-off-by: Ludovic Courtès --- doc/guix.texi | 22 +++++++++++++++++----- 1 file changed, 17 insertions(+), 5 deletions(-) (limited to 'doc') diff --git a/doc/guix.texi b/doc/guix.texi index 09553ab2f3..a675631b79 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -98,6 +98,7 @@ Copyright @copyright{} 2021 pukkamustard@* Copyright @copyright{} 2021 Alice Brenon@* Copyright @copyright{} 2021 Andrew Tropin@* Copyright @copyright{} 2021 Sarah Morgensen@* +Copyright @copyright{} 2021 Josselin Poiret@* Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.3 or @@ -2493,13 +2494,24 @@ mkfs.ext4 -L my-root /dev/sda2 If you are instead planning to encrypt the root partition, you can use the Cryptsetup/LUKS utilities to do that (see @inlinefmtifelse{html, @uref{https://linux.die.net/man/8/cryptsetup, @code{man cryptsetup}}, -@code{man cryptsetup}} for more information). Assuming you want to -store the root partition on @file{/dev/sda2}, the command sequence would -be along these lines: +@code{man cryptsetup}} for more information). + +@quotation Warning +Note that GRUB can unlock LUKS2 devices since version 2.06, but only +supports the PBKDF2 key derivation function, which is not the default +for @command{cryptsetup luksFormat}. You can check which key derivation +function is being used by a device by running @command{cryptsetup +luksDump @var{device}}, and looking for the PBKDF field of your +keyslots. +@end quotation + +Assuming you want to store the root partition on @file{/dev/sda2}, the +command sequence to format it as a LUKS2 partition would be along these +lines: @example -cryptsetup luksFormat /dev/sda2 -cryptsetup open --type luks /dev/sda2 my-partition +cryptsetup luksFormat --type luks2 --pbkdf pbkdf2 /dev/sda2 +cryptsetup open /dev/sda2 my-partition mkfs.ext4 -L my-root /dev/mapper/my-partition @end example -- cgit v1.2.3 From f697fc267c317e98e4bba8009452b9d64e76b30a Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Thu, 2 Dec 2021 14:27:14 -0500 Subject: doc: Give more details about generating patches with base commit information. * doc/contributing.texi (Submitting Patches): Talk more about '--base'. --- doc/contributing.texi | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'doc') diff --git a/doc/contributing.texi b/doc/contributing.texi index aa6bfc2e65..db1c4c6921 100644 --- a/doc/contributing.texi +++ b/doc/contributing.texi @@ -1017,8 +1017,11 @@ please run through this check list: @cindex @code{git format-patch} @cindex @code{git-format-patch} @item -We recommend to use the command @code{git format-patch --base} to -include the commit where your patch applies. +When generating your patches with @code{git format-patch} or @code{git +send-email}, we recommend using the option @code{--base=}, perhaps with +the value @code{auto}. This option adds a note to the patch stating +which commit the patch is based on. This helps reviewers understand how +to apply and review your patches. @item If the authors of the packaged software provide a cryptographic -- cgit v1.2.3 From b42bfbdfe55eea56234a91c33ef12b9fe198766d Mon Sep 17 00:00:00 2001 From: Attila Lendvai Date: Thu, 2 Dec 2021 20:18:56 +0100 Subject: guix system vm: Add --no-graphic CLI argument. It configures QEMU to use the tty it was started in for IO (as opposed to opening a separate graphical window). This enables copy-pasting and scrollback. Exit QEMU with C-a x. * gnu/system/vm.scm (system-qemu-image/shared-store-script): Also add the '-nographic' QEMU argument when called with #:graphic? #false. * guix/scripts/system.scm (system-derivation-for-action): Propagate the #:graphic? keyword arg. (perform-action): Add and propagate the #:graphic? keyword arg. (show-help): Add --no-graphic CLI arg. (%options): Process the new --no-graphic CLI arg. (process-action): Feed in the CLI arg through the #:graphic? keyword arg. * doc/guix.texi (Invoking guix system): Add example to combine guix system and invoking the vm start script into one command. Split the description of the various options into separate paragraphs. Add a paragraph to describe --no-graphic. Signed-off-by: Mathieu Othacehe --- doc/guix.texi | 23 +++++++++++++++++++---- gnu/system/vm.scm | 2 ++ guix/scripts/system.scm | 10 ++++++++++ 3 files changed, 31 insertions(+), 4 deletions(-) (limited to 'doc') diff --git a/doc/guix.texi b/doc/guix.texi index a675631b79..9914829b2b 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -34506,8 +34506,8 @@ passed. @cindex virtual machine @cindex VM @anchor{guix system vm} -Build a virtual machine that contains the operating system declared in -@var{file}, and return a script to run that virtual machine (VM). +Build a virtual machine (VM) that contains the operating system declared +in @var{file}, and return a script to run that VM. @quotation Note The @code{vm} action and others below @@ -34526,6 +34526,12 @@ emulated machine: $ /gnu/store/@dots{}-run-vm.sh -m 1024 -smp 2 -nic user,model=virtio-net-pci @end example +It's possible to combine the two steps into one: + +@example +$ $(guix system vm my-config.scm) -m 1024 -smp 2 -nic user,model=virtio-net-pci +@end example + The VM shares its store with the host system. Additional file systems can be shared between the host and the VM using @@ -34549,8 +34555,17 @@ store of the host can then be mounted. The @option{--full-boot} option forces a complete boot sequence, starting with the bootloader. This requires more disk space since a root image containing at least the kernel, initrd, and bootloader data files must -be created. The @option{--image-size} option can be used to specify the -size of the image. +be created. + +The @option{--image-size} option can be used to specify the size of the +image. + +The @option{--no-graphic} option will instruct @command{guix system} to +spawn a headless VM that will use the invoking tty for IO. Among other +things, this enables copy-pasting, and scrollback. Use the @kbd{ctrl-a} +prefix to issue QEMU commands; e.g. @kbd{ctrl-a h} prints a help, +@kbd{ctrl-a x} quits the VM, and @kbd{ctrl-a c} switches between the +QEMU monitor and the VM. @cindex System images, creation in various formats @cindex Creating system images in various formats diff --git a/gnu/system/vm.scm b/gnu/system/vm.scm index 1e2d8b47c2..0a95302584 100644 --- a/gnu/system/vm.scm +++ b/gnu/system/vm.scm @@ -754,6 +754,8 @@ (define kernel-arguments (define qemu-exec #~(list #+(file-append qemu "/bin/" (qemu-command (or target system))) + ;; Tells qemu to use the terminal it was started in for IO. + #$@(if graphic? '() #~("-nographic")) #$@(if full-boot? #~() #~("-kernel" #$(operating-system-kernel-file os) diff --git a/guix/scripts/system.scm b/guix/scripts/system.scm index 7faa92fd7d..1db788a534 100644 --- a/guix/scripts/system.scm +++ b/guix/scripts/system.scm @@ -689,6 +689,7 @@ (define file-systems (define* (system-derivation-for-action image action #:key full-boot? + (graphic? #t) container-shared-network? mappings) "Return as a monadic value the derivation for IMAGE according to ACTION." @@ -706,6 +707,7 @@ (define* (system-derivation-for-action image action ((vm) (system-qemu-image/shared-store-script os #:full-boot? full-boot? + #:graphic? graphic? #:disk-image-size (if full-boot? image-size @@ -772,6 +774,7 @@ (define* (perform-action action image dry-run? derivations-only? use-substitutes? target full-boot? + (graphic? #t) container-shared-network? (mappings '()) (gc-root #f)) @@ -825,6 +828,7 @@ (define bootcfg (mlet* %store-monad ((sys (system-derivation-for-action image action #:full-boot? full-boot? + #:graphic? graphic? #:container-shared-network? container-shared-network? #:mappings mappings)) @@ -1012,6 +1016,8 @@ (define (show-help) register it as a garbage collector root")) (display (G_ " --full-boot for 'vm', make a full boot sequence")) + (display (G_ " + --no-graphic for 'vm', use the tty that we are started in for IO")) (display (G_ " --skip-checks skip file system and initrd module safety checks")) (display (G_ " @@ -1081,6 +1087,9 @@ (define %options (option '("full-boot") #f #f (lambda (opt name arg result) (alist-cons 'full-boot? #t result))) + (option '("no-graphic") #f #f + (lambda (opt name arg result) + (alist-cons 'no-graphic? #t result))) (option '("save-provenance") #f #f (lambda (opt name arg result) (alist-cons 'save-provenance? #t result))) @@ -1266,6 +1275,7 @@ (define (graph-backend) #:validate-reconfigure (assoc-ref opts 'validate-reconfigure) #:full-boot? (assoc-ref opts 'full-boot?) + #:graphic? (not (assoc-ref opts 'no-graphic?)) #:container-shared-network? (assoc-ref opts 'container-shared-network?) #:mappings (filter-map (match-lambda -- cgit v1.2.3