From 3de898b43c1388a9244bdedd2d9f11511c9571d2 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 9 Nov 2020 13:14:31 -0500 Subject: maint: update-guix-package: Optionally add sources to store. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Following discussions in , keeping a copy of the updated package source is desirable when generating a release. * build-aux/update-guix-package.scm (version-controlled?): Remove variable. (call-with-temporary-git-worktree): Renamed from 'with-temporary-git-worktree'. Update doc. Do not change directory implicitly. Define as a procedure, not a syntax. (keep-source-in-store): New procedure. (main): Adjust to use with call-with-temporary-git-worktree. Add the sources to the store when GUIX_ALLOW_ME_TO_USE_PRIVATE_COMMIT is set. Exit gracefully when FIND-ORIGIN-REMOTE returns #f. (%savannah-guix-git-repo-push-url-regexp): Adjust match for a potential colon separator. * Makefile.am (GUIX_ALLOW_ME_TO_USE_PRIVATE_COMMIT): Adjust. * .dir-locals.el (scheme-mode): Remove entry for with-temporary-git-worktree. * doc/contributing.texi (Updating the Guix Package): Update doc. Co-authored-by: Ludovic Courtès --- doc/contributing.texi | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) (limited to 'doc') diff --git a/doc/contributing.texi b/doc/contributing.texi index d3f6325c3f..d8de71055a 100644 --- a/doc/contributing.texi +++ b/doc/contributing.texi @@ -1368,11 +1368,6 @@ commit that others can't refer to, a check is made that the commit used has already been pushed to the Savannah-hosted Guix git repository. This check can be disabled, @emph{at your own peril}, by setting the -@code{GUIX_ALLOW_ME_TO_USE_PRIVATE_COMMIT} environment variable. - -To build the resulting 'guix' package when using a private commit, the -following command can be used: - -@example -./pre-inst-env guix build guix --with-git-url=guix=$PWD -@end example +@code{GUIX_ALLOW_ME_TO_USE_PRIVATE_COMMIT} environment variable. When +this variable is set, the updated package source is also added to the +store. This is used as part of the release process of Guix. -- cgit v1.2.3 From ac96f2c8369c13dd7d27878ad9426fcda140ef3a Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 11 Nov 2020 22:43:14 -0500 Subject: doc: Detail which bootloader get used with disk-image or vm-image. * doc/guix.texi (Invoking guix system): Extend doc. --- doc/guix.texi | 31 ++++++++++++++++++++++++++----- 1 file changed, 26 insertions(+), 5 deletions(-) (limited to 'doc') diff --git a/doc/guix.texi b/doc/guix.texi index 2f3a474866..104e771562 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -31027,11 +31027,25 @@ a value. Docker images are built to contain exactly what they need, so the @option{--image-size} option is ignored in the case of @code{docker-image}. +@cindex disk-image, creating disk images The @code{disk-image} command can produce various image types. The image type can be selected using the @command{--image-type} option. It -defaults to @code{raw}. When its value is @code{iso9660}, the +defaults to @code{raw}. When its value is @code{iso9660}, the @option{--label} option can be used to specify a volume ID with -@code{disk-image}. +@code{disk-image}. When using @code{disk-image}, the bootloader +installed on the generated image is taken from the provided +@code{operating-system} definition. The following example demonstrates +how to generate an image that uses the @code{grub-efi-bootloader} +bootloader and boot it with QEMU: + +@example +image=$(guix system disk-image --image-type=qcow2 \ + gnu/system/examples/lightweight-desktop.tmpl) +cp $image /tmp/my-image.qcow2 +chmod +w /tmp/my-image.qcow2 +qemu-system-x86_64 -enable-kvm -hda /tmp/my-image.qcow2 -m 1000 + -bios $(guix build ovmf)/share/firmware/ovmf_x64.bin +@end example When using the @code{raw} image type, a raw disk image is produced; it can be copied as is to a USB stick, for instance. Assuming @@ -31045,10 +31059,17 @@ the image to it using the following command: The @code{--list-image-types} command lists all the available image types. +@cindex vm-image, creating virtual machine images When using @code{vm-image}, the returned image is in qcow2 format, which -the QEMU emulator can efficiently use. @xref{Running Guix in a VM}, -for more information on how to run the image in a virtual machine. - +the QEMU emulator can efficiently use. @xref{Running Guix in a VM}, for +more information on how to run the image in a virtual machine. The +@code{grub-bootloader} bootloader is always used independently of what +is declared in the @code{operating-system} file passed as argument. +This is to make it easier to work with QEMU, which uses the SeaBIOS BIOS +by default, expecting a bootloader to be installed in the Master Boot +Record (MBR). + +@cindex docker-image, creating docker images When using @code{docker-image}, a Docker image is produced. Guix builds the image from scratch, not from a pre-existing Docker base image. As a result, it contains @emph{exactly} what you define in the operating -- cgit v1.2.3 From 41f27bf8702838f19b1dc5ffee8eec1d4315d4e6 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Wed, 11 Nov 2020 23:48:12 -0500 Subject: guix: system: Make disk-image root file system non-volatile by default. And add a new '--volatile' option to have it volatile otherwise. * guix/scripts/system.scm (%options)[volatile-root?]: New boolean option. (%default-options): Set its default value to #f. (show-help): Add help doc. * guix/scripts/system.scm (perform-action): Propagate option... (system-derivation-for-action): ...here. Use it to set the volatile-root? field of the image object passed to SYSTEM-IMAGE. * doc/guix.texi (Invoking guix system): Document it. --- doc/guix.texi | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'doc') diff --git a/doc/guix.texi b/doc/guix.texi index 104e771562..cca57140d6 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -31029,10 +31029,12 @@ the @option{--image-size} option is ignored in the case of @cindex disk-image, creating disk images The @code{disk-image} command can produce various image types. The -image type can be selected using the @command{--image-type} option. It +image type can be selected using the @option{--image-type} option. It defaults to @code{raw}. When its value is @code{iso9660}, the @option{--label} option can be used to specify a volume ID with -@code{disk-image}. When using @code{disk-image}, the bootloader +@code{disk-image}. By default, the root file system of a disk image is +mounted non-volatile; the @option{--volatile} option can be provided to +make it volatile instead. When using @code{disk-image}, the bootloader installed on the generated image is taken from the provided @code{operating-system} definition. The following example demonstrates how to generate an image that uses the @code{grub-efi-bootloader} -- cgit v1.2.3 From 11d37090f9ef9610cd1a0dd75cc69ee06dd033ae Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 17 Nov 2020 21:43:22 -0500 Subject: doc: Add a backslash escape to the disk-image example. * doc/guix.texi (Invoking guix system): Add a backslash escape. --- doc/guix.texi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'doc') diff --git a/doc/guix.texi b/doc/guix.texi index cca57140d6..a609d64ee0 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -31045,7 +31045,7 @@ image=$(guix system disk-image --image-type=qcow2 \ gnu/system/examples/lightweight-desktop.tmpl) cp $image /tmp/my-image.qcow2 chmod +w /tmp/my-image.qcow2 -qemu-system-x86_64 -enable-kvm -hda /tmp/my-image.qcow2 -m 1000 +qemu-system-x86_64 -enable-kvm -hda /tmp/my-image.qcow2 -m 1000 \ -bios $(guix build ovmf)/share/firmware/ovmf_x64.bin @end example -- cgit v1.2.3 From 8490fa0253fa8ee5613a89851273e007494ea79b Mon Sep 17 00:00:00 2001 From: Danny Milosavljevic Date: Wed, 18 Nov 2020 09:53:23 +0100 Subject: services: cups: Add some extensions by default. * gnu/services/cups.scm (cups-configuration): Add some extensions by default. doc/guix.texi (Printing Services): Document the default value. --- doc/guix.texi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'doc') diff --git a/doc/guix.texi b/doc/guix.texi index a609d64ee0..99068fccfa 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -17541,7 +17541,7 @@ Available @code{cups-configuration} fields are: The CUPS package. @end deftypevr -@deftypevr {@code{cups-configuration} parameter} package-list extensions +@deftypevr {@code{cups-configuration} parameter} package-list extensions (default: @code{(list escpr hplip-minimal foomatic-filters)}) Drivers and other extensions to the CUPS package. @end deftypevr -- cgit v1.2.3 From 5221df34149465c5bbc1a76f83cb09f8911279f5 Mon Sep 17 00:00:00 2001 From: Julien Lepiller Date: Wed, 18 Nov 2020 14:57:29 +0100 Subject: gnu: vpn: Make ca, key and cert optional. * gnu/services/vpn.scm (openvpn-client-configuration) (openvpn-server-configuration): Make ca, key an cert fields optional. * doc/guix.texi (VPN Services): Document the change. --- doc/guix.texi | 20 ++++++++++++++------ 1 file changed, 14 insertions(+), 6 deletions(-) (limited to 'doc') diff --git a/doc/guix.texi b/doc/guix.texi index 99068fccfa..d021384b73 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -24909,14 +24909,18 @@ Defaults to @samp{tun}. @end deftypevr -@deftypevr {@code{openvpn-client-configuration} parameter} string ca +If you do not have some of these files (eg.@: you use a username and +password), you can disable any of the following three fields by setting +it to @code{'disabled}. + +@deftypevr {@code{openvpn-client-configuration} parameter} maybe-string ca The certificate authority to check connections against. Defaults to @samp{"/etc/openvpn/ca.crt"}. @end deftypevr -@deftypevr {@code{openvpn-client-configuration} parameter} string cert +@deftypevr {@code{openvpn-client-configuration} parameter} maybe-string cert The certificate of the machine the daemon is running on. It should be signed by the authority given in @code{ca}. @@ -24924,7 +24928,7 @@ Defaults to @samp{"/etc/openvpn/client.crt"}. @end deftypevr -@deftypevr {@code{openvpn-client-configuration} parameter} string key +@deftypevr {@code{openvpn-client-configuration} parameter} maybe-string key The key of the machine the daemon is running on. It must be the key whose certificate is @code{cert}. @@ -25060,14 +25064,18 @@ Defaults to @samp{tun}. @end deftypevr -@deftypevr {@code{openvpn-server-configuration} parameter} string ca +If you do not have some of these files (eg.@: you use a username and +password), you can disable any of the following three fields by setting +it to @code{'disabled}. + +@deftypevr {@code{openvpn-server-configuration} parameter} maybe-string ca The certificate authority to check connections against. Defaults to @samp{"/etc/openvpn/ca.crt"}. @end deftypevr -@deftypevr {@code{openvpn-server-configuration} parameter} string cert +@deftypevr {@code{openvpn-server-configuration} parameter} maybe-string cert The certificate of the machine the daemon is running on. It should be signed by the authority given in @code{ca}. @@ -25075,7 +25083,7 @@ Defaults to @samp{"/etc/openvpn/client.crt"}. @end deftypevr -@deftypevr {@code{openvpn-server-configuration} parameter} string key +@deftypevr {@code{openvpn-server-configuration} parameter} maybe-string key The key of the machine the daemon is running on. It must be the key whose certificate is @code{cert}. -- cgit v1.2.3