summaryrefslogtreecommitdiff
path: root/gnu/system.scm
Commit message (Collapse)AuthorAge
* system: Mapped devices needed for boot do not yield Shepherd services.Ludovic Courtès2018-06-21
| | | | | | | | | | | | | | | Fixes <https://bugs.gnu.org/31889>. Reported by Taylan Kammer <taylanbayirli@gmail.com>. * gnu/system.scm (non-boot-file-system-service)[mapped-devices-for-boot]: New variable. Remove dependencies of FS that are members of MAPPED-DEVICES-FOR-BOOT. (mapped-device-user): Rename to... (mapped-device-users): ... this. Use 'filter' instead of 'find'. (operating-system-user-mapped-devices) (operating-system-boot-mapped-devices): Use 'any file-system-needed-for-boot?' instead of looking at the first user. * tests/system.scm ("non-boot-file-system-service"): New test.
* services: boot: Take gexps instead of monadic gexps.Ludovic Courtès2018-06-20
| | | | | | | | | | | | | | | * gnu/services.scm (compute-boot-script): Rename 'mexps' to 'gexps' and remove 'mlet' form. (boot-service-type): Update comment. (cleanup-gexp): Remove 'with-monad' and 'return'. (activation-script): Rewrite in non-monadic style: use 'scheme-file' instead of 'gexp->file'. (gexps->activation-gexp): Remove 'mlet', return a gexp. * gnu/services/shepherd.scm (shepherd-boot-gexp): Remove 'with-monad' and 'return'. * gnu/system.scm (operating-system-boot-script): Remove outdated comment. * gnu/tests/base.scm (%cleanup-os): For 'dirty-service', remove 'with-monad' and 'return'.
* services: boot: Reverse the order of boot expressions.Ludovic Courtès2018-06-20
| | | | | | * gnu/services.scm (compute-boot-script): Reverse MEXPS. * gnu/system.scm (essential-services): Reverse order of %SHEPHERD-ROOT-SERVICE, %ACTIVATION-SERVICE, and CLEANUP-SERVICE-TYPE.
* system: Have /run/setuid-programs first in $PATH.Ludovic Courtès2018-06-18
| | | | | | | | Fixes <https://bugs.gnu.org/31814>. Reported by Clément Lassieur <clement@lassieur.org>. * gnu/system.scm (operating-system-etc-service)["profile"]: Arrange so that /run/setuid-programs comes first in $PATH.
* system: Move ~/.config/guix/current first in PATH and INFOPATH.Ludovic Courtès2018-06-12
| | | | | | | | Fixes <https://bugs.gnu.org/31770>. Reported by iyzsong@member.fsf.org (宋文武). * gnu/system.scm (operating-system-etc-service)["profile"]: Arrange so that ~/.config/guix/current comes first in PATH and INFOPATH.
* system: Honor ~/.config/guix/current in /etc/profile.Ludovic Courtès2018-06-09
| | | | | | * gnu/system.scm (operating-system-etc-service)[profile]: Add ~/.config/guix/current/share/info to INFOPATH. Treat ~/.guix-profile and ~/.config/guix/current in the same way.
* Merge branch 'master' into core-updatesLudovic Courtès2018-06-01
|\
| * system: 'read-boot-parameters' provides a more meaningful warning.Ludovic Courtès2018-05-31
| | | | | | | | | | | | | | 'system' here was bound to Guile's 'system' procedure. * gnu/system.scm (read-boot-parameters): Fix argument for fallback warning.
* | Merge branch 'master' into core-updatesMark H Weaver2018-05-28
|\|
| * file-systems: Remove 'title' field and add <file-system-label>.Ludovic Courtès2018-05-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The 'title' field was easily overlooked and was an endless source of confusion. Now, the value of the 'device' field is self-contained. * gnu/system/file-systems.scm (<file-system>): Change constructor name to '%file-system'. [title]: Remove. (<file-system-label>): New record type with printer. (report-deprecation, device-expression) (process-file-system-declaration, file-system): New macros. (file-system-title): New procedure. (file-system->spec, spec->file-system): Adjust to handle <file-system-label>. * gnu/system.scm (bootable-kernel-arguments): Add case for 'file-system-label?'. (read-boot-parameters): Likewise. (mapped-device-user): Avoid 'file-system-title'. (fs->boot-device): Remove. (operating-system-boot-parameters): Use 'file-system-device' instead of 'fs->boot-device'. (device->sexp): Add case for 'file-system-label?'. * gnu/bootloader/grub.scm (grub-root-search): Add case for 'file-system-label?'. * gnu/system/examples/bare-bones.tmpl, gnu/system/examples/beaglebone-black.tmpl, gnu/system/examples/lightweight-desktop.tmpl, gnu/system/examples/vm-image.tmpl: Remove uses of 'title'. * gnu/system/vm.scm (virtualized-operating-system): Remove uses of 'file-system-title'. * guix/scripts/system.scm (check-file-system-availability): Likewise, and adjust fix-it hint. (check-initrd-modules)[file-system-/dev]: Likewise. * gnu/build/file-systems.scm (canonicalize-device-spec): Remove 'title' parameter. [canonical-title]: Remove. Match on SPEC's type rather than on CANONICAL-TITLE. (mount-file-system): Adjust caller. * gnu/build/linux-boot.scm (boot-system): Interpret ROOT here. * gnu/services/base.scm (file-system->fstab-entry): Remove use of 'file-system-title'. * doc/guix.texi (File Systems): Remove documentation of the 'title' field. Rewrite documentation of 'device' and document 'file-system-label'.
* | Merge branch 'master' into core-updatesMark H Weaver2018-05-21
|\|
| * file-systems: Do not export <file-system>.Ludovic Courtès2018-05-19
| | | | | | | | | | | | * gnu/system/file-systems.scm (<file-system>): Do not export. * gnu/system.scm (operating-system-root-file-system): Use an accessor instead of 'match'.
* | Merge branch 'master' into core-updatesMark H Weaver2018-04-12
|\|
| * system: Provide a fall-back PATH for non-login shells started with su(1).Leo Famulari2018-04-11
| | | | | | | | | | * gnu/system.scm (operating-system-etc-service): Provide values for ENV_PATH and ENV_SUPATH in '/etc/login.defs'.
* | Merge branch 'master' into core-updatesMarius Bakke2018-03-29
|\|
| * gnu: util-linux: Fix CVE-2018-7738 without grafting.Leo Famulari2018-03-20
|/ | | | | | * gnu/packages/linux.scm (util-linux)[replacement]: Remove field. (util-linux-2.31.1): New variable. * gnu/system.scm (%base-packages): Use util-linux-2.31.1.
* services: file-systems: Include 'user-file-systems' service.Ludovic Courtès2018-03-07
| | | | | | | | | | | | | | | | | | | | Previously the KNOWN-FS value used in 'essential-services' would be incomplete: it would lack all the file systems provided by services that extend 'file-system-service-type' (/sys/fs/cgroup, /proc/sys/fs/binfmt_misc, etc.) Consequently, upon shutdown, 'user-processes' would unmount these file systems before their corresponding service had been stopped; when their corresponding (e.g., 'file-system-/proc/sys/fs/binfmt_misc') was stopped, its 'umount' call would fail. This was harmless in practice, but this patch makes sure things work as intended and file systems are unmounted in the right order. * gnu/services/base.scm (file-system-shepherd-services): Instantiate 'user-file-systems' Shepherd service from here. (user-unmount-service-type, user-unmount-service): Remove. * gnu/system.scm (essential-services): Remove call to 'user-unmount-service'. * gnu/system/install.scm (cow-store-service-type): Adjust comment.
* system: Add 'initrd-modules' field.Ludovic Courtès2018-03-02
| | | | | | | | | | | | | | * gnu/system.scm (<operating-system>)[initrd-modules]: New field. (operating-system-initrd-file): Pass #:linux-modules to 'make-initrd'. * gnu/system/linux-initrd.scm (default-initrd-modules): New procedure. (%base-initrd-modules): New macro. (base-initrd): Add #:linux-modules and honor it. * gnu/system/install.scm (embedded-installation-os): Use 'initrd-modules' instead of 'initrd'. * gnu/tests/install.scm (%raid-root-os): Likewise. * doc/guix.texi (operating-system Reference): Add 'initrd-modules'. (Initial RAM Disk): Document it. Adjust example to not use #:extra-modules.
* Merge branch 'master' into core-updatesMark H Weaver2018-01-23
|\
| * services: Missing services are automatically instantiated.Ludovic Courtès2018-01-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This simplifies OS configuration: users no longer need to be aware of what a given service depends on. See the discussion at <https://lists.gnu.org/archive/html/guix-devel/2018-01/msg00114.html>. * gnu/services.scm (missing-target-error): New procedure. (service-back-edges): Use it. (instantiate-missing-services): New procedure. * gnu/system.scm (operating-system-services): Call 'instantiate-missing-services'. * tests/services.scm ("instantiate-missing-services") ("instantiate-missing-services, no default value"): New tests. * gnu/services/version-control.scm (cgit-service-type)[extensions]: Add FCGIWRAP-SERVICE-TYPE. * gnu/tests/version-control.scm (%cgit-os): Remove NGINX-SERVICE-TYPE and FCGIWRAP-SERVICE-TYPE instances. * doc/guix.texi (Log Rotation): Remove 'mcron-service-type' in example. (Miscellaneous Services): Remove 'nginx-service-type' and 'fcgiwrap-service-type' in Cgit example.
* | Merge branch 'master' into core-updatesLeo Famulari2018-01-11
|\|
| * system: Export operating-system-user-kernel-arguments.Danny Milosavljevic2018-01-09
| | | | | | | | * gnu/system.scm (operating-system-user-kernel-arguments): Export it.
* | Merge remote-tracking branch 'origin/master' into core-updatesEfraim Flashner2017-12-31
|\|
| * services: 'user-processes-service-type' can now be extended.Ludovic Courtès2017-12-22
| | | | | | | | | | | | | | | | | | | | | | * gnu/services/base.scm (user-processes-shepherd-service): New procedure, taken from former 'user-processes-service-type'. Add REQUIREMENTS argument; remove GRACE-DELAY argument. (user-processes-service-type): Redefine in terms of 'service-type'. (user-processes-service): Remove. (file-system-service-type): Extend USER-PROCESSES-SERVICE-TYPE. * gnu/system.scm (essential-services): Use USER-PROCESSES-SERVICE-TYPE directly.
* | Merge branch 'master' into core-updatesMarius Bakke2017-12-05
|\|
| * Add semicolon in commands that set GUIX_PROFILE.Ludovic Courtès2017-11-20
| | | | | | | | | | | | | | | | | | | | | | Fixes <https://bugs.gnu.org/28223>. Reported by Rosebud Uplink <Uplink.Introversion@outlook.com>. * doc/guix.texi (Binary Installation): Add missing semicolon after 'GUIX_PROFILE=' line. (Invoking guix package): Likewise. * gnu/system.scm (operating-system-etc-service)[profile]: Likewise. * guix/build/profiles.scm (build-etc/profile): Likewise.
* | Merge branch 'master' into core-updatesMarius Bakke2017-11-19
|\|
| * services: guix: Remove dependency on 'lsof'.Ludovic Courtès2017-11-13
| | | | | | | | | | | | | | | | | | | | This is a followup to b8f59cdc20e9d83ce63523ef917e95fcee07f134: 'list-runtime-roots' no longer depends on 'lsof'. * gnu/services/base.scm (<guix-configuration>)[lsof]: Remove. (guix-shepherd-service): Adjust accordingly. * doc/guix.texi (Base Services): Adjust accordingly. * gnu/system.scm (%base-packages): Remove LSOF.
| * system: Do not set 'TZ'.Ludovic Courtès2017-11-09
| | | | | | | | | | | | | | Fixes <https://bugs.gnu.org/29212>. Reported by Diego Nicola Barbato <dnbarbato@posteo.de>. * gnu/system.scm (operating-system-environment-variables): Remove "TZ".
* | gnu: rfkill: Mark as superseded by util-linux.Efraim Flashner2017-11-02
|/ | | | | | * gnu/packages/linux.scm (rfkill)[properties]: New field, superseded by util-linux. * gnu/system.scm (%base-packages): Remove rfkill.
* system: operating-system-etc-service: Set XCURSOR_PATH.Thomas Danckaert2017-10-10
| | | | | | | * gnu/system.scm (operating-system-etc-service): Set XCURSOR_PATH environment variable so that libxcursor finds cursors in user and system profiles. * gnu/packages/xorg.scm (libxcursor): Add a TODO for better handling of XCURSOR_PATH in other profiles.
* system: Really filter out Linux device names for the store.Ludovic Courtès2017-10-07
| | | | | | | | | | This is a followup to db4e8fd5d4a07d3be8ce68fb96722ef7077c0eee. Fixes <https://bugs.gnu.org/28445>. Reported by Mark H Weaver <mhw@netris.org>. * gnu/system.scm (ensure-not-/dev): New procedure. (read-boot-parameters)[ensure-not-/dev]: Remove. (operating-system-boot-parameters): Use it.
* system: <boot-parameters> does not use "/dev" device names.Ludovic Courtès2017-09-21
| | | | | | | | Fixes <https://bugs.gnu.org/28445>. Reported by Mark H Weaver and Roel Janssen. * gnu/system.scm (read-boot-parameters)[ensure-not-/dev]: New procedure. Use it.
* gnu: system: Fix computation of boot parameters for LUKS devices.Andy Wingo2017-09-20
| | | | | | | | * gnu/system.scm (read-boot-parameters): Fix store-device computation for root devices of type "device", like the LUKS partition described in the manual. From a patch from https://debbugs.gnu.org/cgi/bugreport.cgi?bug=28445#23. Signed-off-by: Andy Wingo <wingo@igalia.com>
* system: Create "/etc/hostname".Thomas Danckaert2017-09-19
| | | | | * gnu/system.scm (operating-system-etc-service): Add a plain-file with the operating-system-host-name.
* system: Define 'DICPATH' in /etc/profile.Ludovic Courtès2017-09-18
| | | | | * gnu/system.scm (operating-system-etc-service) <profile>: Define 'DICPATH'.
* system: Add gexp compiler for <operating-system>.Ludovic Courtès2017-09-12
| | | | * gnu/system.scm (operating-system-compiler): New procedure.
* system: Fix typo in 'read-boot-parameters'.Ludovic Courtès2017-09-11
| | | | | | | | Fixes a regression introduced in commit 075681d3501082c6e22df8abf29dfe89d85effc1. * gnu/system.scm (read-boot-parameters): For 'root-device', use 'device-sexp->device', not 'device->sexp'.
* system: Serialize the UUID type in the "parameters" file.Ludovic Courtès2017-09-11
| | | | | | * gnu/system.scm (read-boot-parameters)[device->sexp]: New procedure. Use it for 'root-device' and 'store-device'. (device->sexp): Serialize the UUID type in addition to its bytevector.
* system: Introduce a disjoint UUID type.Ludovic Courtès2017-09-11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conceptually a UUID is just a bytevector. However, there's software out there such as GRUB that relies on the string representation of different UUID types (e.g., the string representation of DCE UUIDs differs from that of ISO-9660 UUIDs, even if they are actually bytevectors of the same length). This new <uuid> record type allows us to preserve information about the type of UUID so we can eventually convert it to a string using the right representation. * gnu/system/uuid.scm (<uuid>): New record type. (bytevector->uuid): New procedure. (uuid): Return calls to 'make-uuid'. (uuid->string): Rewrite using 'match-lambda*' to accept a single 'uuid?' argument. * gnu/bootloader/grub.scm (grub-root-search): Check for 'uuid?' instead of 'bytevector?'. * gnu/system.scm (bootable-kernel-arguments): Check whether ROOT-DEVICE is 'uuid?'. (read-boot-parameters): Use 'bytevector->uuid' when the store device is a bytevector. (read-boot-parameters-file): Check for 'uuid?' instead of 'bytevector?'. (device->sexp): New procedure. (operating-system-boot-parameters-file): Use it for 'root-device' and 'store'. (operating-system-bootcfg): Remove conditional in definition of 'root-device'. * gnu/system/file-systems.scm (file-system->spec): Check for 'uuid?' on DEVICE and take its bytevector. * gnu/system/mapped-devices.scm (open-luks-device): Likewise. * gnu/system/vm.scm (iso9660-image): Call 'uuid-bytevector' for the #:volume-uuid argument.
* Merge branch 'master' into core-updatesMarius Bakke2017-08-01
|\
| * bootloader: Use <menu-entry> for the bootloader side.Danny Milosavljevic2017-07-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * gnu/bootloader.scm (menu-entry-device-mount-point): New variable. Export it. (<menu-entry>: New field "device". * gnu/bootloader/grub.scm (grub-confgiuration-file): Handle <menu-entry> entries. * gnu/bootloader/extlinux.scm (extlinux-configuration-file): Handle <menu-entry> entries. * gnu/system.scm (menu->entry->boot-parameters): Delete variable. (boot-parameters->menu-entry): New variable. Export it. (operating-system-bootcfg): Make OLD-ENTRIES a list of <menu-entry>. * guix/script/system.scm (reinstall-bootloader): Fix bootcfg usage. (perform-action): Fix bootcfg usage.
* | Merge branch 'master' into core-updatesLeo Famulari2017-07-23
|\|
| * gnu: Add support for aarch64's compiled kernel.Efraim Flashner2017-07-23
| | | | | | | | | | | | * gnu/packages/linux.scm (linux-libre)[arguments]: Add to the regex to find and install the aarch64-linux kernel. * gnu/system.scm (system-linux-image-file-name): Add entry for aarch64.
* | Merge branch 'master' into core-updatesLeo Famulari2017-07-23
|\|
| * system: Add 'newuidmap' and 'newgidmap' to %SETUID-PROGRAMS.宋文武2017-07-18
| | | | | | | | * gnu/system.scm (%setuid-programs): Add 'newuidmap' and 'newgidmap'.
| * locale: Demonadify the locale creation API.Ludovic Courtès2017-07-17
| | | | | | | | | | | | | | | | * gnu/system/locale.scm (single-locale-directory): Use 'computed-file' instead of 'gexp->derivation'. (locale-directory): Adjust accordingly and do the same. * gnu/system.scm (operating-system-directory-base-entries): Adjust accordingly.
* | system: Avoid collision between GMP variants in the global profile.Ludovic Courtès2017-06-30
| | | | | | | | | | * gnu/system.scm (%base-packages): Move GUILE-2.2 out of the list passed to 'canonical-package'.
* | Merge branch 'master' into core-updatesLudovic Courtès2017-06-30
|\|
| * system: Use "@" to refer to the 'shadow' package.Ludovic Courtès2017-06-30
| | | | | | | | | | | | | | | | | | Reported by Mark H Weaver at <https://lists.gnu.org/archive/html/guix-devel/2017-06/msg00349.html>. * gnu/system.scm (%base-packages): Use '@' for shadow. This fixes an error on Guile 2.0 where 'shadow' alone resolves to the (gnu system shadow) module.