me
/
guix
Archived
1
0
Fork 0
Commit Graph

1155 Commits (467583fab5f319c5f30446843c1a5805ae2ff0ad)

Author SHA1 Message Date
Ludovic Courtès 49f82fca41
mapped-devices: luks: Specify modules needed at the top-level.
Fixes <https://issues.guix.gnu.org/70266>.

* gnu/system/mapped-devices.scm (luks-device-mapping)[modules]: New
field.
(open-luks-device): Remove non-top-level ‘use-modules’ form.
* gnu/system/linux-initrd.scm (raw-initrd): Remove modules that were
added specifically for ‘luks-device-mapping’.

Change-Id: I4253c3dd5e3cbcee41ec84fd57227abd428d1bd6
2024-04-08 00:17:57 +02:00
Ludovic Courtès 6062339156
mapped-devices: <mapped-device-type> can specify modules to import.
* gnu/system/mapped-devices.scm (<mapped-device-type>)[modules]: New
field.
(device-mapping-service-type): Honor it.
* gnu/system/linux-initrd.scm (raw-initrd): Likewise.

Change-Id: Icc702cb6f281741975e33203f87fbc1ffa9856da
2024-04-08 00:13:25 +02:00
Zheng Junjie 16c7130835
vm: If not the same local architecture, don't enable kvm.
* gnu/system/vm.scm (common-qemu-options): Add target keyword.

Change-Id: Ic9bf18cf60ac5ce623289df31ea050a22c6e604e
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2024-03-31 22:28:11 +02:00
Zheng Junjie e6241de15a
vm: add arguments to use virt machine type for qemu-riscv64.
* gnu/system/vm.scm (system-qemu-image/shared-store-script): When target
riscv64, add arguments to set qemu virt machine type.

Change-Id: I974c82fdd2d5bfc01caff9e6411db38e472b5cd4
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2024-03-31 22:28:01 +02:00
Zheng Junjie 88a300852f
linux-initrd: don't add hid-apple module for riscv64-linux.
* gnu/system/linux-initrd.scm(default-initrd-modules): when target-riscv64,
don't add hid-apple module.

Change-Id: I633468421db0cb1ebd61e0603021fa1c79038473
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2024-03-31 22:27:48 +02:00
Zheng Junjie ad9832f82e
vm: When target riscv64-linux, use u-boot-qemu-riscv64-bootloader.
* gnu/system/vm.scm (virtualized-operating-system) When target riscv64-linux,
use u-boot-qemu-riscv64-bootloader. Add system, target keyword.

Change-Id: I22d64d00670a705e4b81427e44a83d504598b536
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2024-03-31 22:27:02 +02:00
Zheng Junjie a5deb90fd4
vm: use #$ for kernel-arguments.
Use #$ allow cross-compile to with support current system kernel.

e.g. linux-libre-riscv64-generic.

* gnu/system/vm.scm(system-qemu-image/shared-store-script)
(linux-image-startup-command): use #$ for kernel-arguments.

Change-Id: I9d2e7df296ce590b95cd30996b33f8ca692ac1b1
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2024-03-31 22:26:27 +02:00
Hilton Chain 8f8ec56052
linux-initrd: Avoid looking up builtin modules.
* gnu/system/linux-initrd.scm (flat-linux-module-directory)
[build-exp]<builtin-modules,modules-to-lookup>: New variables.
<modules>: Use ‘modules-to-lookup’ to avoid looking up builtin modules.

Change-Id: I60fdae0211bb6632508b1c63582e013e78186cd1
2024-03-09 09:21:19 +08:00
Florian Pelz bc6840316c
system: default-bash-profile: Add Guix Home search paths as well.
Ordinary .guix-profile is searched already.  Also this makes desktop
environments find packages installed in Guix Home.

* gnu/system/shadow.scm (%default-bash-profile): Add Home search paths.
2024-02-28 16:55:20 +01:00
Ludovic Courtès 9edbb2d7a4
services: Add ‘virtual-build-machine’ service.
* gnu/services/virtualization.scm (<virtual-build-machine>): New record type.
(%build-vm-ssh-port, %build-vm-secrets-port, %x86-64-intel-cpu-models):
New variables.
(qemu-cpu-model-for-date, virtual-build-machine-ssh-port)
(virtual-build-machine-secrets-port): New procedures.
(%minimal-vm-syslog-config, %virtual-build-machine-operating-system):
New variables.
(virtual-build-machine-default-image):
(virtual-build-machine-account-name)
(virtual-build-machine-accounts)
(build-vm-shepherd-services)
(initialize-build-vm-substitutes)
(build-vm-activation)
(virtual-build-machine-offloading-ssh-key)
(virtual-build-machine-activation)
(virtual-build-machine-secret-root)
(check-vm-availability)
(build-vm-guix-extension): New procedures.
(initialize-hurd-vm-substitutes): Remove.
(hurd-vm-activation): Rewrite in terms of ‘build-vm-activation’.
* gnu/system/vm.scm (linux-image-startup-command): New procedure.
(operating-system-for-image): Export.
* gnu/tests/virtualization.scm (run-command-over-ssh): New procedure,
extracted from…
(run-childhurd-test): … here.
[test]: Adjust accordingly.
(%build-vm-os): New variable.
(run-build-vm-test): New procedure.
(%test-build-vm): New variable.
* doc/guix.texi (Virtualization Services)[Virtual Build Machines]: New
section.
(Build Environment Setup): Add cross-reference.

Change-Id: I0a47652a583062314020325aedb654f11cb2499c
2024-02-10 23:21:07 +01:00
Ludovic Courtès b0a5c0742f
vm: Add ‘cpu-count’ field to <virtual-machine>.
* gnu/system/vm.scm (<virtual-machine>)[cpu-count]: New field.
(virtual-machine-compiler): Honor it.

Change-Id: I907a89365f32ac7a9981c4ae5f59cf6eb199c3cc
2024-02-10 22:59:52 +01:00
Ludovic Courtès 7a4f585ae1
vm: Export <virtual-machine> accessors.
* gnu/system/vm.scm: Export.

Change-Id: If65d96f4052d070af5baee26f3dd9b233b8480f4
2024-02-10 22:59:49 +01:00
Ludovic Courtès f7447b1a32
vm: Add ‘date’ field to <virtual-machine>.
* gnu/system/vm.scm (<virtual-machine>)[date]: New field.
(virtual-machine-compiler): Honor it.

Change-Id: Idab1c152466d57cbc6784c031a99fdfd37080bcb
2024-02-10 22:59:46 +01:00
Leo Nikkilä 841fd4880a
linux-container: Inherit essential services.
Currently it's not possible to set `essential-services' when building
operating systems for containers, since `container-essential-services'
always uses the defaults.

It's possible to reference `essential-services' from the operating
system that's passed in, but since it's thunked, the operating system
needs to be defined in two passes to avoid an infinite loop.

* gnu/system/linux-container.scm (container-essential-services): Use
operating-system-essential-services instead of the defaults to allow
overriding the base services.
(containerized-operating-system): Update accordingly.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
Change-Id: I81452487ef1ad01d3fa874c26d93a67d58ce6062
2024-02-05 22:29:45 +01:00
Tomas Volf 21989dd57d
image: Consider grub-efi-removable-bootloader to be EFI bootloader.
Without this change, trying to create a system image with efi-raw type while
using grub-efi-removable-bootloader fails with fairly confusing message:

    EFI bootloader required with GPT partitioning

* gnu/system/image.scm (system-disk-image): Consider
grub-efi-removable-bootloader to be EFI bootloader.

Change-Id: I5f5e1a94e825fd29d6880c5bafb330e16a5ac962
2024-01-17 11:17:59 +01:00
Efraim Flashner 5ef5095ab1
system: default-zprofile: Sync with home zprofile.
The removed fields are already sourced in /etc/profile.

* gnu/system/shadow.scm (%default-zprofile): Sync with default zprofile
from (gnu home services shells).

Change-Id: I419eadf636344e23e8fd2f7006efa81f45527756
2024-01-17 11:11:10 +02:00
Efraim Flashner 1e8ac2c41b
system: Add default guix-home-config.
* gnu/system/shadow.scm (%deafult-skeleton-home-config): New variable.
(default-skeletons): Add it.

Change-Id: Ida4cca8b1b3674491a4f18d94bc1b12d426575ba
2024-01-17 11:11:10 +02:00
Efraim Flashner 3ca02f0304
system: Export default guile config.
* gnu/system/shadow.scm (%default-dotguile): Extract from
default-skeletons, export.
(default-skeletons): Use %default-dotguile.

Change-Id: Ibe91b3b517ae542bd28070a08e14152f87ed75ec
2024-01-17 11:11:09 +02:00
Efraim Flashner 33136e0426
system: Export default nanorc.
* gnu/system/shadow.scm (%default-nanorc): Extract from
default-skeletons, export.
(default-skeletons): Use %default-nanorc.

Change-Id: I0d07b13ed4894b1152a08b96d9ef8527dde073ce
2024-01-17 11:11:09 +02:00
Efraim Flashner eef3babfdb
system: Export default gdbinit.
* gnu/system/shadow.scm (%default-gdbinit): Extract from
default-skeletons, export.
(default-skeletons): Use %default-gdbinit.

Change-Id: Ia5188f8083a83ad4cdb96e234dbd730b1bfe0072
2024-01-17 11:11:09 +02:00
Efraim Flashner 7292838874
system: Export default xdefaults.
* gnu/system/shadow.scm (%default-xdefaults): Extract from
default-skeletons, export.
(default-skeletons): Use %default-xdefaults.

Change-Id: I44018516ec3687a68d32ca5c86c41bc29507a273
2024-01-17 11:11:09 +02:00
Efraim Flashner 6a9e4b0639
system: Export default zprofile.
* gnu/system/shadow.scm (%default-zprofile): Extract from
default-skeletons, export.
(default-skeletons): Use %default-zprofile.

Change-Id: I6c6e158bca2e462a2eae709fbc2c25a2c7f3f8b4
2024-01-17 11:11:09 +02:00
Efraim Flashner cdcb2e78d2
system: Export default bash-profile.
gnu/system/shadow.scm (%default-bash-profile): Extract from
default-skeletons, export.
(default-skeletons): Use %default-bash-profile.

Change-Id: I45641b1091daee3495a5f92bdc1a63050e0cc59e
2024-01-17 11:11:03 +02:00
Tomas Volf d082312ef7
mapped-devices: Allow unlocking by a key file.
Requiring the user to input their password in order to unlock a device is not
always reasonable, so having an option to unlock the device using a key file
is a nice quality of life change.

* gnu/system/mapped-devices.scm (open-luks-device): Add #:key-file argument.
(luks-device-mapping-with-options): New procedure.
* doc/guix.texi (Mapped Devices): Describe the new procedure.

Change-Id: I1de4e045f8c2c11f9a94f1656e839c785b0c11c4
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2024-01-14 23:00:03 +01:00
Ludovic Courtès b973480dc9
system: hurd: Use the Shepherd 0.10.x.
* gnu/system.scm (hurd-default-essential-services): Remove reference to
‘shepherd-0.8’.
* gnu/system/hurd.scm (%base-packages/hurd): Replace ‘shepherd-0.8’ with
‘shepherd-0.10’.

Change-Id: I9f1800693cda456286450d3d0bb6f7e3da85d55e
2024-01-08 23:14:46 +01:00
Oleg Pykhalov 519e1e3eb8
scripts: system: Build layered images.
* guix/scripts/system.scm (show-help, %docker-format-options, %options,
%default-options, show-docker-format-options,
show-docker-format-options/detailed, process-action): Handle '--max-layers'
option.
* gnu/system/image.scm (system-docker-image): Same.
* gnu/image.scm (<image>)[max-layers]: New record field.

Change-Id: I2726655aefd6688b976057fd5a38e9972ebfc292
2024-01-08 21:22:44 +03:00
Maxim Cournoyer 1d4db94beb
gnu: vm-image.tmpl: Improve SPICE dynamic resizing.
* gnu/system/examples/vm-image.tmpl (auto-update-resolution-crutch): Delete
variable.
(operating-system) [packages]: Add x-resize.
[services]: Remove auto-update-resolution-crutch mcron service.

Fixes: https://issues.guix.gnu.org/57068
Reported-by: Ludovic Courtès <ludo@gnu.org>
Change-Id: I45cd3d79b94ece2511d324c7b180f8f37bd9ba49
2023-12-30 00:28:14 -05:00
Herman Rimm ab1ff7ca40
images: Add orangepi-r1-plus-lts image.
* gnu/local.mk: Register image.
* gnu/system/images/orangepi-r1-plus-lts-rk3328.scm: New file.
* gnu/system/install.scm (orangepi-r1-plus-lts-rk3328-installation-os):
  New variable.

Signed-off-by: Vagrant Cascadian <vagrant@debian.org>
2023-12-22 16:06:15 -08:00
Leo Nikkilä cd8ea377d7
file-systems: Add tracefs to %pseudo-file-system-types.
* gnu/system/file-systems.scm (%pseudo-file-system-types): Add tracefs.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2023-12-10 21:47:52 +01:00
Janneke Nieuwenhuizen b0715d7cd2
gnu: Use ‘libc-utf8-locales-for-target’.
* guix/packages.scm (%standard-patch-inputs): Use
‘libc-utf8-locales-for-target’ instead of ‘glibc-utf8-locales’.
* guix/self.scm (%packages): Likewise.
* gnu/home/services/ssh.scm (file-join): Likewise
* gnu/installer.scm (build-compiled-file): Likewise.
* gnu/packages/chromium.scm (ungoogled-chromium/wayland): Likewise.
* gnu/packages/gnome.scm (libgweather4, tracker): Likewise.
* gnu/packages/javascript.scm (js-mathjax): Likewise.
* gnu/packages/package-management.scm (guix, flatpak): Likewise.
* gnu/packages/raspberry-pi.scm (raspi-arm64-chainloader): Likewise.
* gnu/packages/suckless.scm (svkbd): Likewise.
* gnu/services.scm (cleanup-gexp): Likewise.
* gnu/services/base.scm (guix-publish-shepherd-service): Likewise.
* gnu/services/guix.scm (guix-build-coordinator-shepherd-services)
(guix-build-coordinator-agent-shepherd-services): Likewise.
* gnu/services/guix.scm (guix-build-coordinator-queue-builds-shepherd-services):
(guix-data-service-shepherd-services)
(nar-herder-shepherd-services)
(bffe-shepherd-services): Likewise.
* gnu/services/web.scm (anonip-shepherd-service)
(mumi-shepherd-services): Likewise.
* gnu/system/image.scm (system-disk-image, system-iso9660-image)
(system-docker-image, system-tarball-image): Likewise.
* gnu/system/install.scm (%installation-services): Likewise.
* guix/profiles.scm (info-dir-file): Likewise.
(ca-certificate-bundle, profile-derivation): Likewise.
* guix/scripts/pack.scm (store-database, set-utf8-locale): Likewise.
* tests/pack.scm: Likewise.
* tests/profiles.scm ("profile-derivation, cross-compilation"):
Likewise.

Co-authored-by: Ludovic Courtès <ludo@gnu.org>
Co-authored-by: Christopher Baines <mail@cbaines.net>
Change-Id: I24239f427bcc930c29d2ba5d00dc615960a6c374
2023-12-02 12:25:45 +01:00
Tobias Geerinckx-Rice 2059b9fbe0
system: vm: Include the cirrus driver in the initrd.
This is Ludo's suggestion at <https://issues.guix.gnu.org/36069#26>,
with an added guard against duplicates and a tweaked comment.

* gnu/system/vm.scm (virtualized-operating-system): Add "cirrus" to the
list of INITRD-MODULES.

Co-authored-by: Ludovic Courtès <ludo@gnu.org>
Change-Id: I1a86286586eee0b8c39706544778c7911a86da33
2023-10-29 02:00:00 +02:00
Skyler Ferris 593a2e6354
gnu: file-systems: Add xenfs to %pseudo-file-system-types.
* gnu/system/file-systems.scm (%pseudo-file-system-types): Add xenfs.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2023-10-30 00:20:42 +01:00
Bruno Victal 70c27db33e
system: Modify bash skeleton to colorize 'ip' output.
* gnu/system/shadow.scm (%default-bashrc): Add an alias for 'ip' that enables
output colorization.

Signed-off-by: Mathieu Othacehe <othacehe@gnu.org>
2023-10-06 11:52:13 +02:00
Nikolaos Chatzikonstantinou 2467b7d1fb
system: bare-bones: Add comments about nss-cert and NTP service.
TLS errors may be confusing to some users.  Two comments are added: one
comment should help clarify the extra step required for root CA certificates
to be installed, while the other will help users keep their clocks
synchronized, another source of TLS errors due to clock drift.

* gnu/system/examples/bare-bones.tmpl: Add nss-cert and NTP service comments.

Signed-off-by: Nikolaos Chatzikonstantinou <nchatz314@gmail.com>
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2023-10-05 23:14:54 +02:00
Ludovic Courtès 97927608cb
Revert "system: accounts: Export <user-account>."
This reverts commit 03795e2ba2.
Fixes <https://issues.guix.gnu.org/66279>.
2023-10-05 23:14:54 +02:00
Ludovic Courtès f5c3f8e59e
system: vm: Remove unused variable.
This is a followup to 05a9d1f378, which
removed its sole user.

* gnu/system/vm.scm (%linux-vm-file-systems): Remove.
(mapping->file-system): Add comment about “cache=loose”.
2023-10-01 22:58:18 +02:00
Mathieu Othacehe dfaeaae9c7
image: Product hybrid qcow2 images.
This is a follow-up of e5ed1712da. Restore the
behaviour before d57cab7641 and produce
hybrid, BIOS and UEFI capable qcow2 images.

* gnu/system/image.scm (qcow2-image-type): Inherit from mbr-hybrid-disk-image.
2023-10-01 22:18:52 +02:00
Mathieu Othacehe 6bd17a0806
image: Do not allow BIOS bootloader and GPT.
When using grub-bootloader with a GPT image, GRUB will fail during
installation with a cryptic error message.

* gnu/system/image.scm (system-disk-image): Raise an error when trying to use
a non-EFI compatible bootloader with a GPT image partitioning.

Signed-off-by: Mathieu Othacehe <othacehe@gnu.org>
2023-09-20 09:38:40 +02:00
Mathieu Othacehe e5ed1712da
image: Introduce the mbr-hybrid-raw image type.
Until 209204e23b and
d57cab7641, the default image type used by "guix
system image" was an MBR image with an ESP partition.

Having both an MBR image and an ESP partition is handy because the image will
boot on most x86 based systems using legacy BIOS and/or UEFI.

We now have a distinction between MBR images and EFI images. Introduce a new
MBR hybrid image type and default to it to restore the default behaviour.

This also fixes the images section of (gnu ci) that was trying to install a
BIOS bootloader on an EFI, GPT image and failing to do so.

Signed-off-by: Mathieu Othacehe <othacehe@gnu.org>
2023-09-20 09:38:36 +02:00
Nicolas Graves d4da1f26e1
gnu: file-systems: Add variable %base-live-file-systems.
* gnu/system/file-systems.scm (%base-live-file-systems): New variable.
* gnu/system/install.scm (installation-os): Use %base-live-file-systems.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2023-09-17 15:31:04 +02:00
Janneke Nieuwenhuizen 41df5c5289
system: hurd: Override locale-libcs harder.
This really removes the locale-2.33 dependency running `guix system build
bare-hurd.tmpl' on the Hurd, that somehow still managed to leak-in?

* gnu/system/hurd.scm (%base-packages/hurd)[locale-libcs]: New field.
2023-09-16 15:35:25 +02:00
Janneke Nieuwenhuizen bd303443be
system: hurd: Add nss-certs to %base-packages/hurd.
This fixes the recently added "rewrite-url, to-version specified" test.

* gnu/system/hurd.scm (%base-packages/hurd): Add nss-certs.
2023-09-16 15:35:25 +02:00
Janneke Nieuwenhuizen 64929be426
system: hurd: Add procps to %base-packages/hurd.
* gnu/system/hurd.scm (%base-packages/hurd): Add procps.
2023-09-16 15:35:25 +02:00
Janneke Nieuwenhuizen f2cfb4a85c
locale: Set %default-locale-definitions to glibc/hurd on the Hurd.
* gnu/system/locale.scm (%default-locale-libcs): Use only glib/hurd when
building on the Hurd.
2023-09-16 15:35:25 +02:00
Efraim Flashner ab971e9c19
system: vm-image: Remove duplicate packages.
* gnu/system/examples/vm-image.tmpl (use-package-modules): Remove
unneeded modules.
(operating-system)[packages]: Remove nvi, wget.
2023-09-11 10:56:03 +03:00
Tobias Geerinckx-Rice 5a2c3352d8
Revert "gnu: system: Add home-directory-permissions field to <user-account>."
This reverts commit e9a5eebc78, which
as far as I can tell breaks system roll-backs thusly:

[...]
In gnu/build/accounts.scm:
   239:27  3 (_ #<<password-entry> name: "root" password: "x" uid: 0 gid: 0 real-name: "System >)
In unknown file:
           2 (string-join ("root" "x" "0" "0" "System administrator" "/root" #t) ":" #<undefined>)
In ice-9/boot-9.scm:
  1685:16  1 (raise-exception _ #:continuable? _)
  1685:16  0 (raise-exception _ #:continuable? _)

ice-9/boot-9.scm:1685:16: In procedure raise-exception:
In procedure string-append: Wrong type (expecting string): #t
2023-08-20 02:00:00 +02:00
David Thompson e9a5eebc78
gnu: system: Add home-directory-permissions field to <user-account>.
* gnu/system/accounts.scm (<user-account>)[home-directory-permissions]: New
field.
(user-account-home-directory-permissions): New accessor.
* gnu/build/activation.scm (activate-users+groups): Use home directory
permission bits from the user account object.
* doc/guix.texi (User Accounts): Document new field.

Signed-off-by: Josselin Poiret <dev@jpoiret.xyz>
2023-08-25 15:12:54 +02:00
Josselin Poiret d57cab7641
image: Add mbr-raw-image-type and use by default.
* gnu/system/image.scm (mbr-disk-image, mbr-raw-image-type): New variables.
(qcow2-image-type): Inherit mbr-disk-image.
* guix/scripts/system.scm (%default-options): Use mbr-raw-image-type by
default.
* gnu/tests/install.scm (run-install): Use mbr-raw in the tests.
* doc/guix-cookbook.texi (Guix System Image API): Update the list of image
types.
* doc/guix.texi (Invoking guix system, System Images, image-type Reference):
Add mbr-raw and switch documented default to it.
2023-08-25 14:24:21 +02:00
Ludovic Courtès 30355c17d7
examples: Avoid duplicate SDDM service for Plasma on aarch64-linux.
This is a followup to cf28f46930.

* gnu/system/examples/plasma.tmpl (services): Remove both
'gdm-service-type' and 'sddm-service-type' from %DESKTOP-SERVICES.
2023-08-22 01:14:47 +02:00
Ludovic Courtès cf28f46930
examples: Avoid 'modify-services' to remove GDM.
This led to a 'tests/guix-system.sh' failure on aarch64-linux:

  …/plasma.tmpl:60:13: error: modify-services: service 'gdm' not found in service list

This is because 'gdm-service-type' is not among %DESKTOP-SERVICES on
that architecture.

* gnu/system/examples/plasma.tmpl (services): Use 'remove' rather
'modify-services' + 'delete'.
2023-08-21 23:06:49 +02:00