Commit Graph

274 Commits

Author SHA1 Message Date
Maxim Cournoyer 129b9b16d9
Merge remote-tracking branch 'origin/version-1.2.0' into master
Conflicts:
	gnu/packages/bioinformatics.scm

The python-pysam package fixed in master was kept instead of the update done
in the version-1.2.0 branch.
2020-11-17 18:00:28 -05:00
Marius Bakke 6cad3f6966
services: mingetty: Export configuration accessors.
* gnu/services/base: Export configuration accessors for mingetty.
2020-11-16 19:08:36 +01:00
Ludovic Courtès 977eb5d023
Properly deal with build directories containing '~'.
Fixes <https://bugs.gnu.org/44626>.
Reported by Vagrant Cascadian <vagrant@debian.org>.

* tests/build-utils.scm ("wrap-script, simple case"): Pass
SCRIPT-CONTENTS to 'display' rather than 'format'.
* gnu/services/base.scm (file-system->shepherd-service-name)
[valid-characters, mount-point]: New variables.
Filter out invalid store file name characters from the mount point of
FILE-SYSTEM.
2020-11-16 11:21:42 +01:00
Mark H Weaver e3ae313478
gnu: mingetty-shepherd-service: Make 'clear-on-logout' configurable.
Also change the default configuration to clear on logout, which is the
upstream default.

* gnu/services/base.scm (<mingetty-configuration>): Add 'clear-on-logout?'
field.
(mingetty-shepherd-service): Pass the "--noclear" option to mingetty only if
'clear-on-logout?' is #false.
* doc/guix.texi (Base Services): Document the 'clear-on-logout?' field.
2020-11-11 00:21:22 -05:00
Ludovic Courtès f7d0a63dda
services: guix: Do not embed the host (guix config).
Fixes a bug whereby different users would get different derivations for
the same service.

* gnu/services/base.scm (guix-shepherd-service): In 'start' method, do
not embed (guix config).
2020-11-05 00:07:45 +01:00
Ludovic Courtès 2b2ab7796a
services: guix-publish: Add 'cache-bypass-threshold' field.
This is a followup to ecaa102a58.

* gnu/services/base.scm (<guix-publish-configuration>)[cache-bypass-threshold]:
New field.
(guix-publish-shepherd-service): Honor it.
2020-10-30 12:31:18 +01:00
Ludovic Courtès 81c3dd9cad
services: swap: Allow for UUIDs and file system labels.
* gnu/services/base.scm (swap-service-type)[device-lookup, device-name]:
New variables.
Add 'modules' field to 'shepherd-service'.  In 'start' and 'stop', use
'device-lookup' to resolve UUIDs and labels.
* doc/guix.texi (operating-system Reference): Adjust accordingly.
2020-10-30 01:14:21 +01:00
Ludovic Courtès 3b6e4e5fd0
services: guix: Make /etc/guix/acl really declarative by default.
Fixes <https://bugs.gnu.org/39819>.
Reported by Maxim Cournoyer <maxim.cournoyer@gmail.com>.

* gnu/services/base.scm (substitute-key-authorization): Symlink
DEFAULT-ACL to /etc/guix/acl unconditionally.  Add code to optionally
back up /etc/guix/acl if it was possibly modified by hand.
* doc/guix.texi (Base Services): Clarify the effect of setting
'authorize-keys?' to true.  Mention the backup.  Give an example showing
how to authorize substitutes from another server.
2020-10-25 01:06:10 +02:00
Ludovic Courtès d367a7f3d0
services: guix: Generate key pair if needed during activation.
* gnu/services/base.scm (guix-activation): Invoke "guix archive
--generate-key".
* doc/guix.texi (Invoking guix archive)
(Invoking guix deploy): Mention that 'guix-service-type' takes care of
generating the key pair.
2020-09-29 21:56:27 +02:00
Mathieu Othacehe 1a0da8b4f3
services: base: Improve container related comments.
* gnu/services/base.scm (guix-shepherd-service): Clarify the usage of a
container for guix-daemon.
2020-09-21 10:48:16 +02:00
Mathieu Othacehe 8ce6f4dc28
installer: Run the installation inside a container.
When the store overlay is mounted, other processes such as kmscon, udev
and guix-daemon may open files from the store, preventing the
underlying install support from being umounted. See:
https://lists.gnu.org/archive/html/guix-devel/2018-12/msg00161.html.

To avoid this situation, mount the store overlay inside a container,
and run the installation from within that container.

* gnu/build/shepherd.scm (fork+exec-command/container): New procedure.
* gnu/services/base.scm (guix-shepherd-service): Support an optional PID
argument passed to the "start" method. If that argument is passed, ensure that
guix-daemon enters the given PID MNT namespace by using
fork+exec-command/container procedure.
* gnu/installer/final.scm (umount-cow-store): Remove it,
(install-system): run the installation from within a container.
* gnu/installer/newt/final.scm (run-install-shell): Remove the display hack.
2020-09-02 17:05:23 +02:00
Mathieu Othacehe dac7dd1b0b
Remove "guile-zlib" extension when unused.
This is a follow-up of 755f365b02.

As (zlib) is autoloaded in (gnu build linux-modules), "guile-zlib" is needed
as an extension only when it is effectively used.

* gnu/installer.scm (installer-program): Remove "guile-zlib" from the extensions.
* gnu/machine/ssh.scm (machine-check-initrd-modules): Ditto.
* gnu/services.scm (activation-script): Ditto.
* gnu/services/base.scm (default-serial-port): Ditto,
(agetty-shepherd-service): ditto,
(udev-service-type): ditto.
* gnu/system/image.scm (gcrypt-sqlite3&co): Ditto.
* gnu/system/shadow.scm (account-shepherd-service): Ditto.
2020-08-25 12:39:11 +02:00
Mathieu Othacehe 755f365b02
linux-libre: Support module compression.
This commit adds support for GZIP compression for linux-libre kernel
modules. The initrd modules are kept uncompressed as the initrd is already
compressed as a whole.

The linux-libre kernel also supports XZ compression, but as Guix does not have
any available bindings for now, and the compression time is far more
significant, GZIP seems to be a better option.

* gnu/build/linux-modules.scm (modinfo-section-contents): Use
'call-with-gzip-input-port' to read from a module file using '.gz' extension,
(strip-extension): new procedure,
(dot-ko): adapt to support compression,
(ensure-dot-ko): ditto,
(file-name->module-name): ditto,
(find-module-file): ditto,
(load-linux-module*): ditto,
(module-name->file-name/guess): ditto,
(module-name-lookup): ditto,
(write-module-name-database): ditto,
(write-module-alias-database): ditto,
(write-module-device-database): ditto.
* gnu/installer.scm (installer-program): Add "guile-zlib" to the extensions.
* gnu/machine/ssh.scm (machine-check-initrd-modules): Ditto.
* gnu/services.scm (activation-script): Ditto.
* gnu/services/base.scm (default-serial-port): Ditto,
(agetty-shepherd-service): ditto,
(udev-service-type): ditto.
* gnu/system/image.scm (gcrypt-sqlite3&co): Ditto.
* gnu/system/linux-initrd.scm (flat-linux-module-directory): Add "guile-zlib"
to the extensions and make sure that the initrd only contains
uncompressed module files.
* gnu/system/shadow.scm (account-shepherd-service): Add "guile-zlib" to the
extensions.
* guix/profiles.scm (linux-module-database): Ditto.
2020-08-25 11:53:20 +02:00
Oleg Pykhalov cc339cd98d
services: base: Export references-file.
* gnu/services/base.scm (references-file): Export procedure.
2020-07-22 22:10:10 +03:00
Marius Bakke d67826a810
services: Remove obsolete comment.
This TODO was resolved in ea4915a74b.

* gnu/services/base.scm (%default-authorized-guix-keys): Remove TODO comment.
2020-07-12 13:06:41 +02:00
Christopher Lemmer Webber ea4915a74b
services: guix: Refer to 'berlin.guix.gnu.org.pub'.
Commit 6680880f9b pushes out a new guix
package with a new key location, so we need to update to the new key
in order for systems to build correctly.

* gnu/services/base.scm (%default-authorized-guix-keys): Refer to berlin.guix.gnu.org.pub.
2020-07-11 21:42:04 -04:00
Ludovic Courtès ec4c404c05
services: guix: Refer to 'berlin.guixsd.org.pub'.
This partly reverts d283bb960f.

* gnu/services/base.scm (%default-authorized-guix-keys): Refer to berlin.guixsd.org.pub.
2020-07-10 11:48:05 +02:00
Ludovic Courtès d283bb960f
maint: Remove traces of "berlin.guixsd.org".
The guixsd.org domain is no longer advertised since before in 1.0.0
release in May 2019.

* etc/substitutes/berlin.guixsd.org.pub: Rename to...
* etc/substitutes/berlin.guix.gnu.org.pub: ... this.
* etc/substitutes/ci.guix.gnu.org.pub,
etc/substitutes/ci.guix.info.pub: Adjust accordingly.
* gnu/services/base.scm (%default-authorized-guix-keys): Likewise.
* guix/build/download-nar.scm (urls-for-item): Likewise.
* guix/self.scm (miscellaneous-files): Likewise.
* Makefile.am (dist_pkgdata_DATA): Likewise.
2020-07-10 00:11:00 +02:00
Marius Bakke 4bdf4182fe
Merge branch 'core-updates' 2020-05-08 21:40:51 +02:00
Ludovic Courtès 5aa4d2dcf2
Revert "services: syslog: Simplify 'start' method."
This reverts commit 4c0cc7bed3.
Fixes <https://bugs.gnu.org/41116>.
Reported by Alex Sassmannshausen <alex@komputilo.eu>.

The problem is that reconfiguring on a system running Shepherd < 0.8.0
would lead to an error, due to #:file-creation-mask not being supported.
The error is rather harmless: it prevents service upgrade but the system
itself is upgraded.

We can reinstate that commit eventually, once #:file-creation-mask has
become widespread.
2020-05-07 12:55:15 +02:00
Marius Bakke 87a40d7203
Merge branch 'master' into core-updates 2020-05-05 20:43:21 +02:00
Giacomo Leidi ec4fea69df
services: For "sddm" pam service, include "limits.conf".
* gnu/services/base.scm (pam-limits-service-type): For "sddm" pam
service, include "limits.conf".

Signed-off-by: Marius Bakke <mbakke@fastmail.com>
2020-05-05 20:09:39 +02:00
Marius Bakke 50e6c1bf2e
Merge branch 'master' into core-updates 2020-05-02 17:31:28 +02:00
Diego Nicola Barbato 4c0cc7bed3
services: syslog: Simplify 'start' method.
This is a followup to d7113bb655 and
e3358a831e.

* gnu/services/base.scm (syslog-service-type): Change 'start' method to set
  umask using the #:file-creation-mask parameter of
  'make-forkexec-constructor' introduced in version 0.8.0 of the Shepherd.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2020-05-02 16:49:29 +02:00
Marius Bakke 030f6f489f
Merge branch 'master' into core-updates
Conflicts:
	etc/news.scm
	gnu/local.mk
	gnu/packages/bootloaders.scm
	gnu/packages/linphone.scm
	gnu/packages/linux.scm
	gnu/packages/tls.scm
	gnu/system.scm
2020-04-23 13:33:09 +02:00
Brice Waegeneire 2b0c0d9301
services: Add udev-rules-service helper.
* doc/guix.texi (Base services): Add documentation for
'udev-rules-service'. Replace examples of 'udev-service-type' extension
with 'udev-rules-service'.
* gnu/services/base.scm (udev-rules-service): New procedure.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2020-04-22 19:23:58 +02:00
Ludovic Courtès 7d903d2ff7
services: Don't use the deprecated 'make-forkexec-constructor' call.
Passing 'make-forkexec-constructor' a string or several string arguments
has been deprecated since dmd 0.1.

* gnu/services/base.scm (rngd-service-type): In 'start' method, pass a
list as the first argument to 'make-forkexec-constructor'.
* gnu/services/desktop.scm (bluetooth-shepherd-service): Likewise.
* gnu/services/spice.scm (spice-vdagent-shepherd-service): Likewise.
2020-04-21 00:06:40 +02:00
Marius Bakke 7abe35febe
Merge branch 'master' into core-updates 2020-04-19 16:53:01 +02:00
Ludovic Courtès 10c413685f
services: Move 'user-processes' to (gnu services shepherd).
* gnu/services/base.scm (%do-not-kill-file)
(user-processes-shepherd-service, user-processes-service-type): Move
to...
* gnu/services/shepherd.scm: ... here.
2020-04-17 23:18:32 +02:00
Marius Bakke 2778302399
Merge branch 'master' into core-updates
Conflicts:
	etc/news.scm
	gnu/local.mk
	gnu/packages/check.scm
	gnu/packages/cross-base.scm
	gnu/packages/gimp.scm
	gnu/packages/java.scm
	gnu/packages/mail.scm
	gnu/packages/sdl.scm
	gnu/packages/texinfo.scm
	gnu/packages/tls.scm
	gnu/packages/version-control.scm
2020-04-08 13:00:50 +02:00
Ludovic Courtès 3302e03ba0
services: guix: Add 'set-http-proxy' action.
Fixes <https://bugs.gnu.org/25569>.
Reported by Divan Santana <divan@santanas.co.za>.

* gnu/services/base.scm (shepherd-set-http-proxy-action): New procedure.
(guix-shepherd-service): Add 'actions' field.  Change 'start' to a
lambda; check the value of the "http_proxy" environment variable and
add "http_proxy" and "https_proxy" to #:environment-variables as a
function of that.
* gnu/tests/base.scm (run-basic-test)["guix-daemon set-http-proxy
action", "guix-daemon set-http-proxy action, clear"]: New tests.
* doc/guix.texi (Base Services): Document it.
2020-04-07 12:31:36 +02:00
Ludovic Courtès d7113bb655
services: syslog: Create log files as non-world-readable.
Partly fixes <https://bugs.gnu.org/40405>.
Reported by Diego Nicola Barbato <dnbarbato@posteo.de>.

* gnu/services/base.scm (syslog-service-type): Change 'start' method to
set umask to #o137 before spawning syslogd.
* gnu/tests/base.scm (run-basic-test)["/var/log/messages is not
world-readable"]: New test.
2020-04-06 23:56:24 +02:00
Ludovic Courtès 0468455e7d
services: Add 'rottlog-service-type' to '%base-services'.
* gnu/services/base.scm (%base-services): Add an instance of
ROTTLOG-SERVICE-TYPE.
* doc/guix.texi (Log Rotation): Mention that it's part of
%BASE-SERVICES and change example.
2020-04-06 12:07:49 +02:00
Marius Bakke 18af687037
Merge branch 'master' into core-updates
Conflicts:
	gnu/packages/icu4c.scm
	gnu/packages/man.scm
	gnu/packages/python-xyz.scm
	guix/scripts/environment.scm
	guix/scripts/pack.scm
	guix/scripts/package.scm
	guix/scripts/pull.scm
	guix/store.scm
2020-03-27 00:12:15 +01:00
Ludovic Courtès ae5c4a9292
services: console-font: Fix docstring.
* gnu/services/base.scm (console-font-service-type): Use quasiquote and
unquote appropriately in docstring.
2020-03-23 00:06:58 +01:00
Marius Bakke d594963856
gnu: eudev: Remove bugfix variant.
* gnu/packages/linux.scm (eudev/btrfs-fix): Remove variable.
(eudev)[arguments]: Add phase patch-bindir-in-btrfs-rules.
* gnu/services/base.scm (<udev-configuration>, udev-service): Refer to EUDEV
instead of EUDEV/BTRFS-FIX.
2020-03-14 13:19:06 +01:00
Marius Bakke 50b99c90c8
Merge branch 'master' into core-updates 2020-03-10 20:50:02 +01:00
Ludovic Courtès 24a4a635fd
gnu: eudev: Add variant with corrected Btrfs rules.
Discussed at <https://bugs.gnu.org/39926>.

* gnu/packages/linux.scm (eudev/btrfs-fix): New variable.
* gnu/services/base.scm (<udev-configuration>)[udev]: Default to it.
(udev-service): Likewise for #:udev.
2020-03-07 22:30:00 +01:00
Marius Bakke ebb7cf9e21
Merge branch 'master' into core-updates 2020-03-04 23:16:17 +01:00
Florian Pelz 00500449b0
services: udev: Do not rely on shepherd inheriting environment variables.
Fixes <https://bugs.gnu.org/39671>.

* gnu/services/base.scm (udev-shepherd-service)[start] Move or copy
environment variables to 'fork+exec-command' instead of 'setenv'.
2020-02-20 22:34:06 +00:00
Mathieu Othacehe dfc8ccbf5d
system: Stop using canonical-package.
Usage of canonical-package outside of thunked fields breaks cross-compilation,
see: https://lists.gnu.org/archive/html/guix-devel/2019-12/msg00410.html.

* gnu/installer.scm (installer-program): Remove canonical-package.
* gnu/services/base.scm (<nscd-cache>): Ditto,
(%base-services): ditto.
* gnu/services/xorg.scm: Remove useless canonical-package import.
* gnu/system.scm (%base-packages): Remove canonical-package.
* gnu/system/install.scm (%installation-services): Ditto,
(installation-os): ditto.
* gnu/system/locale.scm (single-locale-directory): Ditto.
2020-02-11 13:54:45 +01:00
Efraim Flashner 71fc086ae9
services: host-name: Make service one-shot.
* gnu/services/base.scm (host-name-service-type): Remove 'respawn?'
keyword from shepherd-service-type, add 'one-shot?'.
2020-01-05 20:28:29 +02:00
Jan Nieuwenhuizen 022ad24c41
services: console-font: Update example with HDPI font suggestion.
This solution was kindly provided by Bernard M. Wiedemann.

* gnu/services/base.scm (console-font-service-type): Add ter132n (terminus 132
nomal) font example, for HDPI displays.
* doc/guix.texi (Invoking guix system): Update to `guix system search console'
example output.
2019-12-30 23:40:12 +01:00
Ludovic Courtès 5f15b42273
services: agetty: Really import (gnu build linux-boot).
This is a followup to commit 62c2217570.

* gnu/services/base.scm (agetty-shepherd-service)[start]: Wrap un
'with-imported-modules'.  This fixes a build error when TTY is true
("no code for module (gnu build linux-boot)").
2019-10-21 18:16:16 +02:00
Ricardo Wurmus e08902d3cb
Merge branch 'master' into core-updates 2019-10-06 22:02:20 +02:00
Ludovic Courtès 38b1ea0434
services: udev: Explicitly depend on (gnu build linux-boot).
* gnu/services/base.scm (udev-shepherd-service): Wrap 'start' method in
'with-imported-modules'.
2019-10-06 14:45:35 +02:00
Ludovic Courtès 62c2217570
services: agetty: Explicitly depend on (gnu build linux-boot).
* gnu/services/base.scm (default-serial-port): Wrap in
'with-imported-modules'.
2019-10-06 14:45:35 +02:00
Ludovic Courtès 81bc4533aa
services: urandom-seed: Credit the entropy added to the PRNG.
Partly fixes <https://bugs.gnu.org/37501>.
Reported by Marius Bakke <mbakke@fastmail.com>.

* gnu/services/base.scm (urandom-seed-shepherd-service): In 'start'
method, add calls to 'add-to-entropy-count'.
2019-10-05 22:05:02 +02:00
Jesse Gibbons 0bf7d34d77
services: For "gdm-password" pam service, include "limits.conf".
* gnu/services/base.scm (pam-limits-service-type): For "gdm-password" pam
service, include "limits.conf".

Signed-off-by: Danny Milosavljevic <dannym@scratchpost.org>
2019-10-02 00:48:45 +02:00
Ludovic Courtès 3d8424a5ad
services: Fix /usr/bin/env special file target.
This is a followup to a916215597.

* gnu/services/base.scm (%base-services): Fix "/usr/bin/env" target.
2019-09-12 23:07:42 +02:00