* doc/guix.texi (Mail Services): Update accordingly.
* gnu/services/mail.scm (service-configuration)[process-limit]: New field.
(dovecot-configuration)[services]: Set 'process-limit' to its correct default
value.
* doc/guix.texi (Mail Services): Update accordingly.
* gnu/services/mail.scm (service-configuration)[client-limit]: New field.
(dovecot-configuration)[services]: Set 'client-limit' to its correct default
value.
Add an auto-login option that behaves as the one of mingetty-service.
* gnu/services/base.scm (kmscon-configuration)[auto-login]: New field.
(kmscon-service-type): Pass it to kmscon command.
* doc/guix.texi (Base Services): Document it.
* gnu/services/web.scm (httpd): Make existing httpd-module API public.
* doc/guix.texi (Apache HTTP Server): Document its usage with PHP-FPM.
Signed-off-by: Christopher Baines <mail@cbaines.net>
This is a followup to commit acce0a474c. No
idea how these disappeared.. :-/
* gnu/services/networking.scm (wpa-supplicant-shepherd-service): Add missing
parens.
This allows using WPA Supplicant "standalone" without an additional
network manager. The default configuration is unchanged.
* gnu/services/networking.scm (<wpa-supplicant-configuration>): New record type.
(wpa-supplicant-shepherd-service): Pass configuration records to the daemon.
(wpa-supplicant-service-type): Adjust accordingly.
* doc/guix.texi (Networking Services): Document the new service type.
* gnu/services/admin.scm (default-jobs): Remove the lambda around
"/…/bin/rottlog" to make "herd schedule mcron" more
transparent (otherwise it just says "Lambda function").
* gnu/services/version-control.scm (<gitolite-configuration>,
<gitolite-rc-file>): New record types.
(gitolite-accounts, gitolite-activation): New procedures.
(gitolite-service-type): New variables.
* gnu/tests/version-control.scm (%gitolite-test-admin-keypair, %gitolite-os,
%test-gitolite): New variables.
(run-gitolite-test): New procedure.
* doc/guix.texi (Version Control): Document the gitolite service.
* gnu/services/version-control.scm (<gitolite-configuration>,
<gitolite-rc-file>): New record types.
(gitolite-accounts, gitolite-activation): New procedures.
(gitolite-service-type): New variables.
* gnu/tests/version-control.scm (%gitolite-test-admin-keypair, %gitolite-os,
%test-gitolite): New variables.
(run-gitolite-test): New procedure.
* doc/guix.texi (Version Control): Document the gitolite service.
Fixes a bug in containers whereby 'virtual-terminal' would always fail
to start because writing to /sys/…/default_utf8 would fail with EROFS.
* gnu/services/base.scm (virtual-terminal-service-type): Read from
"default_utf8" before attempting to write to it.
This uses the 'replacement' service slot introduced in the Shepherd
version 0.5.0.
* gnu/services/shepherd.scm (shepherd-service-upgrade): Return a list of
services that need to be restarted to complete their upgrade.
* guix/scripts/system.scm (call-with-service-upgrade-info): Rename an internal
variable to reflect the change to shepherd-service-upgrade.
(upgrade-shepherd-services): Call 'load-services/safe' instead of
'load-services'. Print a message about services that need to be
manually restarted.
* gnu/services/herd.scm (load-services/safe): New procedure.
* doc/guix.texi (Invoking guix system): Document the new behaviour.
Co-authored-by: Ludovic Courtès <ludo@gnu.org>
* gnu/services/web.scm (<varnish-configuration>): New record type.
(%varnish-accounts, %varnish-service-type): New variables.
(varnish-shepherd-service): New procedure.
* gnu/tests/web.scm (%varnish-vcl, %varnish-os): New variables.
(%test-varnish): New test.
* doc/guix.texi (Web Services): Document it.
* gnu/services/networking.scm (<iptables-configuration>): New record type.
(iptables-service-type): New variable.
* gnu/tests/networking.scm (run-iptables-test): New procedure.
(%test-iptables): New variable.
* doc/guix.texi (Networking Services): Document it.
* gnu/services/base.scm (udev-shepherd-service)[start](find): Remove.
(udev): Hardwire the eudev file name.
Use 'fork+exec-command' instead of 'primitive-fork' and 'exec-command'.
This allows (gnu services admin) to remain deeper in the module graph
and to be used by (gnu services web).
* gnu/services/admin.scm (<tailon-configuration-file>)
(tailon-configuration-files-string)
(tailon-configuration-file-compiler, <tailon-configuration>)
(tailon-shepherd-service, %tailon-accounts)
(tailon-service-type): Move to...
* gnu/services/web.scm: ... here.
* gnu/tests/admin.scm: Remove. Move test to...
* gnu/tests/web.scm (%tailon-os)
(run-tailon-test, %test-tailon): ... here.
Previously we'd return #t, which the Shepherd would consider a failure
to stop the service.
* gnu/services/web.scm (nginx-shepherd-service): In 'nginx-action',
return #f when stopping the service.
Fixes <https://bugs.gnu.org/32665>.
* gnu/services/web.scm (nginx-shepherd-service): Check whether FILE is
true and don't read the PID file if it is; use 'read-pid-file' instead
of a potentially endless loop.
* gnu/services/web.scm (nginx-shepherd-service): Change 'start' (that is, all
actions that don't send a signal to the master process) to return the PID.
Wait until the PID file is created and contains an integer because it might be
created after the parent process exits.
* gnu/services/ssh.scm (<openssh-configuration>)[log-level]: New field.
(openssh-config-file): Honor it.
* doc/guix.texi (Networking Services): Document it.
* doc/guix.texi (Networking Services): Document it, and mention that
tor-service is deprecated.
* gnu/services/networking.scm (<tor-configuration>) <socks-socket-type>:
New field.
(tor-configuration->torrc): When socks-socket-type is 'unix, set
SocksPort to UNIX domain socket /var/run/tor/socks-sock and set
UnixSocksGroupWritable to 1.
* gnu/tests/networking.scm (%tor-os/unix-socks-socket): Instead of using
a custom config file, just set socks-socket-type to 'unix.
* gnu/services/networking.scm (tor-configuration->torrc): Set PidFile to
/var/run/tor/tor.pid in the base torrc configuration.
(tor-shepherd-service) <start>: Call make-forkexec-constructor/container with
a new #:pid-file argument to tell Shepherd where to find the PID file. Add a
a new <file-system-mapping> to its existing #:mappings argument to share
/var/run/tor with the the container.
(tor-hidden-services-activation): Update docstring. Create /var/run/tor and
set its permissions so only the tor user can access it.
* gnu/tests/networking.scm (%test-tor, %tor-os): New variables.
(run-tor-test): New procedure.
Fixes: <https://bugs.gnu.org/32478>.
* gnu/services/security-token.scm (pcscd-activation): Idempotently create the
/var/lib/pcsc symlink so that it does not fail when it already exists.
Fixes <https://bugs.gnu.org/32330>.
* gnu/services/cuirass.scm (<cuirass-configuration>)[database]: Change default
from /var/run/cuirass/cuirass.db to /var/lib/cuirass/cuirass.db.
(cuirass-account): Change home directory from /var/run/<user> to
/var/lib/<user>.
Otherwise the global counterpart is never taken into account.
* doc/guix.texi (Version Control Services): Update accordingly.
* gnu/services/cgit.scm (repo-boolean?, serialize-repo-boolean): Use the
DEFINE-MAYBE macro to allow for the 'disabled value.
(repository-cgit-configuration)[enable-commit-graph?, enable-log-filecount?,
enable-log-linecount?, enable-remote-branches?, enable-subject-links?,
enable-html-serving?]: Change default value to 'disabled.
* gnu/services/monitoring.scm (prometheus-node-exporter-service-type):
New variable.
(<prometheus-node-exporter-configuration>): New record type.
(prometheus-node-exporter-shepherd-service): New procedure.
* gnu/doc/guix.texi (Monitoring Services): Document it.
* gnu/tests/monitoring.scm: New file.
* gnu/local.mk (GNU_SYSTEM_MODULES): Add test module.
Fixes <https://bugs.gnu.org/31591>.
* gnu/services/sound.scm (<alsa-configuration>)[alsa-plugins]: New field.
(alsa-config-file): Use 'pcm_type.pulse' and 'ctl_type.pulse' to specify file
paths to the 'pulse' plugin.
* doc/guix.texi (Sound Services): Document this.
Co-authored-by: 宋文武 <iyzsong@member.fsf.org>
* gnu/services/cuirass.scm, gnu/services/pm.scm: Adjust to canonical GPLv3
header used throughout Guix.
Signed-off-by: Leo Famulari <leo@famulari.name>
The previous implementation of 'read-reference-graph' was good enough
for many use cases, but it discarded the graph structure, which is
useful information in some cases.
* guix/build/store-copy.scm (<store-info>): New record type.
(read-reference-graph): Rewrite to return a list of <store-info>.
(closure-size, populate-store): Adjust accordingly.
* gnu/services/base.scm (references-file): Adjust accordingly.
* gnu/system/vm.scm (system-docker-image): Likewise.
* guix/scripts/pack.scm (squashfs-image, docker-image): Likewise.
* tests/gexp.scm ("gexp->derivation #:references-graphs"): Likewise.
This helpful when adding content to the nginx configuration file, which isn't
supported by the record type used for the configuration. For example, like
adding proxy_cache_path configuration.
* gnu/packages/web.scm (<nginx-configuration>): Add new extra-content field.
(nginx-configuration-extra-content): New field accessor.
(default-nginx-config): Add support for the extra-content field.
* doc/guix.texi (NGINX): Document the new extra-content field.
The 'no-negcache?' option is mapped to the '--no-negcache' command-line
argument directly, but we're in the scheme world, where the general guideline
is to avoid double-negations in identifiers.
* gnu/services/dns.scm <dnsmasq-configuration>: Replace the 'no-negcache?'
field with 'negative-cache?'.
* doc/guix.texi (DNS Services)[Dnsmasq Service]: Adjust accordingly.
* gnu/services/dns.scm (dnsmasq-service-type): New variable.
(<dnsmasq-configuration>): New record type.
(dnsmasq-shepherd-service): New procedure.
* doc/guix.texi (DNS Services): Document it.
Fixes a regression introduced in
a5acc17a3c.
Reported by Tobias Geerinckx-Rice <me@tobias.gr>.
* gnu/services/base.scm (file-system->fstab-entry): Pass LABEL, not
FILE-SYSTEM, to 'file-system-label->string'.
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'.
Instead of having the service manage the list, it's useful to be able to point
this at an existing file, for example, when using cgit together with gitolite.
* gnu/services/cgit.scm (project-list?): New procedure.
(serialize-project-list): Handle file-object values.
(<cgit-configuration>): Change the predicate for project-list to allow lists
and file-objects.
* gnu/services/cgit.scm (serialize-cgit-configuration): Add the extra options,
one per line, before the scan-path, as this makes it possible to use the
extra-options to affect the global behaviour for repositories.
(serialize-extra-options): New procedure.
* gnu/services/base.scm (%default-gpm-options): New variable.
(<gpm-configuration>)[gpm, options]: Add default values.
(gpm-service-type)[default-value]: New field.
(gpm-service): Use %DEFAULT-GPM-OPTIONS and mark as deprecated.
* doc/guix.texi (Base Services): Document 'gpm-service-type' and
'gpm-configuration'. Remove 'gpm-service'.
* gnu/services/networking.scm (<dhcpd-configuration>) <version>: Set the
default to "4" instead of "6"; both our manual and upstream says the default
should be "4".
* doc/guix.texi (Networking Services): Document it.
* gnu/services/networking.scm (dhcpd-service-type): Add it.
(dhcpd-configuration, dhcpd-configuration?): Add it.
(dhcpd-configuration-package): Add it.
(dhcpd-configuration-config-file): Add it.
(dhcpd-configuration-version): Add it.
(dhcpd-configuration-run-directory): Add it.
(dhcpd-configuration-lease-file): Add it.
(dhcpd-configuration-pid-file): Add it.
(dhcpd-configuration-interfaces): Add it.
* gnu/tests/networking.scm (minimal-dhcpd-v4-config-file)
(dhcpd-v4-configuration, %dhcpd-os, run-dhcpd-test, %test-dhcpd): New
variables.
* doc/guix.texi (Version Control Services): Update accordingly.
* gnu/services/cgit.scm (cgit-configuration)[project-list]: New field.
(serialize-project-list): New procedure that uses PLAIN-FILE to generate a
file from the string list given by the user as input.
(serialize-cgit-configuration): Make sure to serialize 'project-list' before
'repostory-directory'.
* gnu/services/cgit.scm (serialize-cgit-configuration): New procedure that
serializes fields with a precise order.
(cgit-activation): Replace the generic SERIALIZE-CONFIGURATION with
SERIALIZE-CGIT-CONFIGURATION.
Because it takes too much time and it requires networking.
Thanks to Mathieu Othacehe for suggesting this.
* gnu/services/certbot.scm (certbot-activation): Do not run the renewal
command, copy its path to a fixed location, display it, so that the user can
run the command when they want.
For the default config file representation. This makes it possible to more
easily change the configuration file, and have dynamic content.
* gnu/services/databases.scm (<postgresql-config-file>): New record type.
(%default-postgres-config): Remove this, it's been replaced by the
configuration file.
(<postgresql-configuration>): Alter the default for the config file field.
(postgresql-service): Alter the default value for the config-file parameter.
Many Dovecot utilities compiled with assumption of ‘/etc/dovecot/dovecot.conf’
existence.
* gnu/services/mail.scm (dovecot-shepherd-service): Move config generation.
Invoke ‘dovecot’ without ‘-c’ flag.
(%dovecot-activation): Copy ‘dovecot.conf’ to ‘/etc/dovecot’.
(dovecot-service-type): Make ‘%dovecot-activation’ non-constant.
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.
* gnu/packages/ntp.scm (openntpd)[arguments]: Add 'configure-flags to
set openntpd daemon's user and localstatedir. Add a custom phase to not
try to create said directory at install time.
* gnu/services/networking.scm (<openntpd-configuration>): New record type.
(openntpd-shepherd-service, openntpd-service-activation): New procedures.
(openntpd-service-type): New variable.
* doc/guix.texi (Networking Services): Add openntpd documentation.
* gnu/packages/databases.scm (<postgresql-configuration>)
[config-file,data-directory]: Add default.
(postgresql-service-type)[default-value]:
Set to (postgresql-configuration).
* doc/guix.texi (Messaging Services): Update accordingly.
* gnu/services/configuration.scm (serialize-configuration,
serialize-maybe-stem, serialize-package): Return strings or string-valued
gexps (these procedures were only used for their side-effects).
* gnu/services/messaging.scm (serialize-field, serialize-field-list,
enclose-quotes, serialize-raw-content, serialize-ssl-configuration,
serialize-virtualhost-configuration-list,
serialize-int-component-configuration-list,
serialize-ext-component-configuration-list,
serialize-virtualhost-configuration, serialize-int-component-configuration,
serialize-ext-component-configuration, serialize-prosody-configuration):
Return strings or string-valued gexps and stop printing.
(prosody-activation): Use SERIALIZE-PROSODY-CONFIGURATION's return value with
MIXED-TEXT-FILE instead of using its output with PLAIN-FILE.
(serialize-non-negative-integer, serialize-non-negative-integer-list): Convert
numbers to strings.
(file-object?, serialize-file-object, file-object-list?,
serialize-file-object-list): New procedures.
(ssl-configuration)[capath, cafile], (prosody-configuration)[plugin-paths,
groups-file]: Replace FILE-NAME with FILE-OBJECT.
* guix/gexp.scm (file-like?): New exported procedure.
The certificate name wasn't displayed if it wasn't being renewed.
* gnu/services/certbot.scm (certbot-command): Print certificate name before
running the associated command.
* doc/guix.texi (Certificate Services): Document <certificate-configuration>,
the change from domains to certificates and the fact that their path is now
derived from their name.
* gnu/services/certbot.scm (<certificate-configuration>): Add and export it.
(certbot-configuration, certbot-command, certbot-activation,
certbot-nginx-server-configurations, certbot-service-type): Replace 'domains'
with 'certificates'.
(certbot-nginx-server-configurations): Use only one nginx-server-configuration
and use all certificate domains as the server-name.
* gnu/services/xorg.scm (slim-shepherd-service): Use SESSREG to register X11
session.
* doc/guix.texi (slim-configuration): Document new field "sessreg".
This reverts to the behavior of avahi-daemon prior to Avahi 0.7 (commit
550f4509ac).
* gnu/services/avahi.scm (<avahi-configuration>)[publish-workstation?]:
New field.
(configuration-file): Honor it.
* gnu/services/avahi.scm (%avahi-activation, avahi-shepherd-service):
Use /run/avahi-daemon/ instead of /var/run/avahi-daemon/. This was the
case since the switch to Avahi 0.7 (commit
550f4509ac).
This works around <https://bugs.gnu.org/30396>.
Reported by George myglc2 Clemmer <myglc2@gmail.com>.
* gnu/packages/avahi.scm (nss-mdns-0.10): New variable.
* gnu/services/avahi.scm (avahi-service-type): Use it.
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.
Suggested by atw on #guix.
* gnu/services/shepherd.scm (shepherd-service-file): Use 'scheme-file'
instead of 'gexp->file'.
(shepherd-configuration-file): Likewise, and adjust to non-monadic
style.
(shepherd-boot-gexp): Adjust accordingly.
* guix/scripts/system.scm (upgrade-shepherd-services): Use
'lower-object' in addition to 'shepherd-service-file'.