summaryrefslogtreecommitdiff
path: root/gnu/services/base.scm
Commit message (Collapse)AuthorAge
* services: root-file-system: Cleanly unmount upon shutdown.Ludovic Courtès2022-07-01
| | | | | | | | | | | | Fixes <https://issues.guix.gnu.org/56209>. Reported by angry rectangle <angryrectangle@cock.li>. * gnu/packages/admin.scm (shepherd-0.9)[modules, snippet]: New fields. * gnu/services/base.scm (%root-file-system-shepherd-service): In 'stop' method, remove 'call-with-blocked-asyncs'. When 'mount' throws to 'system-error, call (@ (fibers) sleep) and try again. * gnu/tests/base.scm (run-root-unmount-test): New procedure. (%test-root-unmount): New variable.
* services: greetd: Remove unnecessary user groups.Lars-Dominik Braun2022-06-30
| | | | | * gnu/services/base.scm (%greetd-accounts): Remove supplementary groups users, tty, input, audio. Create special user group “greeter”.
* gnu: base: Add greetd-service-type.muradm2022-06-17
| | | | | | | | | | | | | * gnu/services/base.scm (greetd-service-type): New variable * gnu/services/base.scm (greetd-configuration): New data type * gnu/services/base.scm (greetd-terminal-configuration): New data type * gnu/services/base.scm (greetd-agreety-session): New data type * gnu/services/base.scm (pam-limits-service-type): Should be aware of greetd PAM service * gnu/services/pam-mount.scm (pam-mount-pam-service): Should be aware of greetd PAM service Signed-off-by: Lars-Dominik Braun <ldb@leibniz-psychology.org>
* services: guix: Generalize extensions.terramorpha2022-06-13
| | | | | | | | | * gnu/services/base.scm (<guix-extension>): New record type. (guix-extension-merge): New procedure. (guix-service-type): Honor extensions. * doc/guix.texi (Base Services): Document it. Signed-off-by: Ludovic Courtès <ludo@gnu.org>
* services: syslogd: Do not fsync at each line.Ludovic Courtès2022-06-06
| | | | | | | | | | | | | Fixes <https://issues.guix.gnu.org/55707>. Previously Inetutils' syslogd would call 'fsync' after each line written to a file. This would significantly increase boot times on machines with slow-ish spinning HDDs, where each 'fsync' call would take between 0.1s and 0.4s (and we'd do two of them for each line, one for /var/log/messages and one for /var/log/debug). * gnu/services/base.scm (%default-syslog.conf): Add a '-' before each file name, except /var/log/secure. Change what goes to /var/log/debug.
* services: pam-limits: Add sudo and sshd.Kiran Shila2022-06-05
| | | | | | | * gnu/services/base.scm (pam-limits-service-type): Add "sudo" and "sshd" to the list. Signed-off-by: Ludovic Courtès <ludo@gnu.org>
* services: Add more description fields.Ludovic Courtès2022-05-18
| | | | | | | * gnu/services.scm (simple-service): Add 'description' field. * gnu/services/base.scm (udev-rules-service): Likewise. * gnu/system/install.scm (configuration-template-service-type): Likewise. * gnu/tests.scm (marionette-service-type): Likewise.
* services: Make sure Shepherd destructors match constructors.Ludovic Courtès2022-05-02
| | | | | | | | | | | | | This is a followup to b06ecc57515d4e3c8b2228e8142654e9a26ba6e1, 211fe3f66e6dfdaa64974931c458ab1d92afc182, and fd57ce267c4083fe98242caa31075d2bd62903bf. * gnu/services/base.scm (guix-publish-shepherd-service): Change 'stop' method to use 'make-systemd-destructor' when 'make-systemd-constructor' is used. * gnu/services/dict.scm (dicod-shepherd-service): Change 'stop' method to use 'make-inetd-destructor' when 'make-inetd-constructor' is used. * gnu/services/messaging.scm (bitlbee-shepherd-service): Likewise.
* gexp: Add 'references-file'.Ludovic Courtès2022-05-01
| | | | | | * gnu/services/base.scm (references-file): Remove. * guix/gexp.scm (references-file): New procedure. * tests/gexp.scm ("references-file"): New test.
* services: guix-publish: Use socket activation when possible.Ludovic Courtès2022-04-29
| | | | | * gnu/services/base.scm (guix-publish-shepherd-service): Use 'make-systemd-constructor' when it's available and ADVERTISE? is false.
* services: Add 'log-cleanup' service to '%base-services' for build logs.Ludovic Courtès2022-04-04
| | | | | | * gnu/services/base.scm (%base-services): Add 'log-cleanup-service-type' instance. * doc/guix.texi (Log Rotation): Add example and mention '%base-services'.
* services: guix: Add 'generate-substitute-key?' field.Ludovic Courtès2022-03-10
| | | | | | | * gnu/services/base.scm (<guix-configuration>)[generate-substitute-key?]: New field. (guix-activation): Honor it. * doc/guix.texi (Base Services): Document it.
* agetty-shepherd-service: Rename console agetty to "term-console" for clarity.Danny Milosavljevic2022-02-25
| | | | | * gnu/services/base.scm (agetty-shepherd-service)[provision]: Rename console agetty to "term-console".
* services: %base-services: Adapt agetty-service-type to depend on syslogdDanny Milosavljevic2022-02-25
| | | | | | | Fixes <https://issues.guix.gnu.org/30464>. * gnu/services/base.scm (%base-services): Reorder syslog-service for clarity. [shepherd-requirement]: New field.
* services: agetty: Add shepherd-requirement.Danny Milosavljevic2022-02-25
| | | | | * gnu/services/base.scm (<agetty-configuration>): Add shepherd-requirement. * doc/guix.texi (agetty-configuration): Document it.
* services: udev: Use a fixed location for the rules directory and config.Maxim Cournoyer2022-02-20
| | | | | | | | | | | | | | | | | | | Fixes <https://issues.guix.gnu.org/47681>. This change adjusts the location of the udev configuration file and rules directory to a fixed location. Since udev relies on inotify to discover change to its rules directory (/etc/udev/rules.d), by using a fixed directory layout, new udev rules can be automatically picked up without restarting the service. * gnu/services/base.scm (udev-rules-union): Build rules output directly in #$output. (udev-shepherd-service)[start]: Adjust the UDEV_CONFIG_FILE and EUDEV_RULES_DIRECTORY environment variables. [actions]: Remove field. The 'rules' action is no longer useful. (udev.conf): New variable. (udev-etc): New procedure. (udev-service-type): Extend the etc-service-type with it.
* services: guix-publish: Add negative-ttl parameter.Guillaume Le Vaillant2022-01-20
| | | | | | | | * gnu/services/base.scm (guix-publish-configuration): Add 'negative-ttl' field. (guix-publish-sheperd-service): Process it. * doc/guix.texi (Base Services)[guix-publish-service-type]: Add item for negative-ttl.
* daemon: Always default to gzip for log compression.Ludovic Courtès2022-01-18
| | | | | | | | * nix/libstore/globals.cc (Settings::Settings): Have 'logCompression' default to COMPRESSION_GZIP unconditionally. * gnu/services/base.scm (<guix-configuration>)[log-compression]: Default to 'gzip. * doc/guix.texi (Invoking guix-daemon, Base Services): Adjust accordingly.
* services: guix: Add tar and gzip to PATH.Timothy Sample2022-01-16
| | | | | * gnu/services/base.scm (guix-shepherd-service): Add the PATH environment-variable and populate it with tar and gzip.
* services: networking: Add netmask to loopback address.Ludovic Courtès2022-01-08
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously, we would get a fishy 127.0.0.1/0 interface: $ ip a show dev lo 1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000 link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00 inet 127.0.0.1/8 scope host lo valid_lft forever preferred_lft forever inet 127.0.0.1/0 scope global lo valid_lft forever preferred_lft forever inet6 ::1/128 scope host valid_lft forever preferred_lft forever With this change, we get nothing but the "/8" version: $ ip a show dev lo 1: lo: <LOOPBACK,MULTICAST,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000 link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00 inet 127.0.0.1/8 scope global lo valid_lft forever preferred_lft forever inet6 ::1/128 scope host valid_lft forever preferred_lft forever Reported by Yann Dupont <Yann.Dupont@univ-nantes.fr>. * gnu/services/base.scm (assert-valid-address): Remove special cases for 127.0.0.1 and ::1. (%loopback-static-networking): Add "/8".
* services: static-networking: Enable multicast by default.Mathieu Othacehe2021-12-21
| | | | | | Fixes: <https://issues.guix.gnu.org/52520>. * gnu/services/base.scm (network-set-up/linux): Enable it.
* services: static-networking: Sanitize <network-address> values.Ludovic Courtès2021-12-20
| | | | | | | | This makes sure users do not mistakenly configuring a network with "/0" as its netmask. * gnu/services/base.scm (assert-valid-address): New procedure. (<network-address>)[value]: Add it as 'sanitize'.
* services: Define '%loopback-static-networking'.Ludovic Courtès2021-12-12
| | | | | | | | * gnu/services/base.scm (%loopback-static-networking): New variable. (%base-services): Use it. * gnu/system/hurd.scm (%base-services/hurd): Use it. * gnu/system/install.scm (%installation-services): Use it. * doc/guix.texi (Networking Setup): Document it.
* services: Define '%qemu-static-networking'.Ludovic Courtès2021-12-12
| | | | | | * gnu/services/base.scm (%qemu-static-networking): New variable. * gnu/system/hurd.scm (%base-services/hurd): Use it. * doc/guix.texi (Networking Setup): Document it.
* services: static-networking: Change interface to mimic netlink.Ludovic Courtès2021-12-12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * gnu/services/base.scm (<static-networking>)[interface, ip, netmask] [gateway]: Remove. [addresses, links, routes]: New fields. [requirement]: Default to '(udev). (<network-address>, <network-link>, <network-route>): New record types. (ensure-no-separate-netmask, %ensure-no-separate-netmask): Remove. (ipv6-address?, cidr->netmask, ip+netmask->cidr) (network-set-up/hurd, network-tear-down/hurd) (network-set-up/linux, network-tear-down/linux) (static-networking->hurd-pfinet-options): New procedures. (static-networking-shepherd-service): New procedure. (static-networking-shepherd-services): Rewrite in terms of the above. (static-networking-service): Deprecate. Adjust to new 'static-networking' API. (%base-services): Likewise. * gnu/system/install.scm (%installation-services): Likewise. * gnu/system/hurd.scm (%base-services/hurd): Likewise, and separate 'loopback' from 'networking'. * gnu/build/hurd-boot.scm (set-hurd-device-translators): Remove "servers/socket/2". * gnu/tests/networking.scm (run-openvswitch-test)["networking has started on ovs0"]: Check for 'networking instead of 'networking-ovs0, which is no longer provided. * doc/guix.texi (Networking Setup): Document the new interface. Remove documentation of 'static-networking-service'. (Virtualization Services): Change Ganeti example to use the new interface.
* services: static-networking: Use Guile-Netlink on GNU/Linux.Ludovic Courtès2021-12-12
| | | | | | | * gnu/services/base.scm (static-networking-shepherd-service): Define 'set-up-via-ioctl', 'tear-down-via-ioctl', 'set-up-via-netlink', 'tear-down-via-netlink', and 'helpers' and use them in 'start' and 'stop'. Add (ip *) modules to 'modules'.
* services: Accept <inferior-package>s in lieu of <package>s.Tobias Geerinckx-Rice2021-11-30
| | | | | | | | | | | | | | | | | | | | | | | | | * gnu/services/authentication.scm (fprintd-configuration) (nslcd-configuration): Substitute file-like objects for package ones. * gnu/services/cgit.scm (cgit-configuration, opaque-cgit-configuration): Likewise. * gnu/services/cups.scm (package-list?, cups-configuration): Likewise. * gnu/services/dns.scm (verify-knot-configuration) (ddclient-configuration): Likewise. * gnu/services/docker.scm (docker-configuration): Likewise. * gnu/services/file-sharing.scm (transmission-daemon-configuration): Likewise. * gnu/services/getmail.scm (getmail-configuration): Likewise. * gnu/services/mail.scm (dovecot-configuration) (opaque-dovecot-configuration): Likewise. * gnu/services/messaging.scm (prosody-configuration) (opaque-prosody-configuration): Likewise. * gnu/services/monitoring.scm (zabbix-server-configuration) (zabbix-agent-configuration): Likewise. * gnu/services/networking.scm (opendht-configuration): Likewise. * gnu/services/pm.scm (tlp-configuration): Likewise. * gnu/services/telephony.scm (jami-configuration): Likewise. * gnu/services/virtualization.scm (libvirt-configuration) (qemu-guest-agent-configuration): Likewise. * gnu/services/vpn.scm (openvpn-client-configuration): Likewise.
* gnu: system: Make old-style swap use default flags.Josselin Poiret2021-11-23
| | | | | | | * gnu/services/base.scm (swap-service-type): Use default flags (0) if SWAP is not a new-style <swap-space> record. Signed-off-by: Tobias Geerinckx-Rice <me@tobias.gr>
* system: Add swap flags.Josselin Poiret2021-11-23
| | | | | | | | | | | * gnu/system/file-systems.scm (swap-space)[priority, discard?]: Add them. * guix/build/syscalls.scm (SWAP_FLAG_PREFER, SWAP_FLAG_PRIO_MASK, SWAP_FLAG_PRIO_SHIFT, SWAP_FLAG_DISCARD): Add them. * gnu/build/file-systems.scm (swap-space->flags-bit-mask): Add it. * gnu/services/base.scm (swap-service-type): Use it. Signed-off-by: Ludovic Courtès <ludo@gnu.org>
* system: Rework swap space support, add dependencies.Josselin Poiret2021-11-23
| | | | | | | | | | | | * gnu/system/file-systems.scm (swap-space): Add it. * gnu/system.scm (operating-system)[swap-devices]: Update comment. * gnu/services/base.scm (swap-space->shepherd-service-name, swap-deprecated->shepherd-service-name, swap->shepherd-service-name): Add them. * gnu/services/base.scm (swap-service-type, swap-service): Use the new records. Signed-off-by: Ludovic Courtès <ludo@gnu.org>
* services: base: Honor file-system-create-mount-point? at all times.Maxim Cournoyer2021-08-29
| | | | | | | | | | Fixes <https://issues.guix.gnu.org/40158>. * gnu/services/base.scm (file-system-shepherd-service): Update doc. Return a shepherd service for the mount point when either MOUNT? or CREATE? is true. [start]: Only mount when MOUNT? is true. (file-system-shepherd-services): Also consider file systems with create-mount-point? set to #t.
* services: pam-limits: fix limits.conf locationmuradm2021-08-07
| | | | | | | | * gnu/services/base.scm: fix limits.conf location This fixes #49771 Signed-off-by: Julien Lepiller <julien@lepiller.eu>
* services: guix: Use "match-record" in activation.Brice Waegeneire2021-08-04
| | | | | | | | It's more explicit to specify used fields instead of depending on their position. * gnu/services/base.scm (guix-activation): Replace "match" with "match-record".
* services: gpm: Use "make-forkexec-contstructor".Brice Waegeneire2021-07-13
| | | | | * gnu/services/base.scm (gpm-shepherd-service)[start]: Replace custom logic with "make-forkexec-constructor".
* services: kmscon: Add keyboard-layout fields.luhui2021-06-29
| | | | | | | * gnu/services/base.scm (<kmscon-configuration>): Add keyboard-layout fields. * doc/guix.texi (Base Services): Document them. Signed-off-by: Mathieu Othacehe <othacehe@gnu.org>
* services: guix: Authorize 'bordeaux.guix.gnu.org.pub' by default.Jack Hill2021-06-19
| | | | | | | | | This follows on from the changes in 4985a4272497bf9ba87a2190353d915da9b55906. * gnu/services/base.scm (%default-authorized-guix-keys): Add bordeaux.guix.gnu.org.pub. Signed-off-by: Christopher Baines <mail@cbaines.net>
* services: Remove deprecated service procedures.Ludovic Courtès2021-06-14
| | | | | | | | | | | | | | | These service procedures were deprecated in January 2019, for instance in commit 65a67bf711b14bc7200f6730c0f173375ca12974. * gnu/services/avahi.scm (avahi-service): Remove. * gnu/services/base.scm (console-keymap, guix-service) (guix-publish-service, gpm-service, urandom-seed-service): Remove. * gnu/services/desktop.scm (upower-service, colord-service): Remove. * gnu/services/mcron.scm (mcron-service): Remove. * gnu/services/messaging.scm (bitlbee-service): Remove. * gnu/services/networking.scm (dhcp-client-service, ntp-service) (tor-service): Remove. * gnu/services/xorg.scm (slim-service, gdm-service): Remove.
* services: guix-publish: Add zstd compression by default.Ludovic Courtès2021-04-03
| | | | | | | | | | | That way, the default config with (advertises? #t) and without a cache will offer zstd-compressed substitutes, which should lead to much higher throughput than gzip. * gnu/services/base.scm (default-compression): When 'guix-publish-configuration-cache' returns true, use higher level compression ratios. Add "zstd". * doc/guix.texi (Base Services): Mention zstd.
* services: kmscon: Add font-engine and font-size fields.qblade2021-04-01
| | | | | | | * gnu/services/base.scm (<kmscon-configuration>): Add font-engine and font-size fields. (kmscon-service-type): Honor them. * doc/guix.texi (Base Services): Document them.
* services: Enable "protected hardlinks" and "protected symlinks" by default.Leo Famulari2021-03-18
| | | | | | | | | | | | | | References: https://sysctl-explorer.net/fs/protected_hardlinks/ https://sysctl-explorer.net/fs/protected_symlinks/ * gnu/services/sysctl.scm (%default-sysctl-settings): New public variable. (<sysctl-configuration>): Use %default-sysctl-settings as the default value. * gnu/services/base.scm (%base-services): Add sysctl-service-type. * doc/guix.texi (Miscellaneous Services): Document the new defaults. Signed-off-by: Ludovic Courtès <ludo@gnu.org>
* services: shepherd: 'shepherd-service-type' requires documentation.Ludovic Courtès2021-01-13
| | | | | | | | | | | | | | | | | * gnu/services/shepherd.scm (shepherd-service-type): Require a 'description' form. * gnu/services/base.scm (root-file-system-service-type) (rngd-service-type, host-name-service-type): (virtual-terminal-service-type, console-keymap-service-type) (syslog-service-type, swap-service-type) (kmscon-service-type): Add description. * gnu/services/networking.scm (dhcp-client-service-type): Likewise. * gnu/system/install.scm (cow-store-service-type): Likewise. * gnu/system/linux-container.scm (dummy-networking-service-type): Likewise. * gnu/system/mapped-devices.scm (device-mapping-service-type): Likewise. * tests/guix-system.sh: Likewise.
* services: 'references-file' depends on Guile-Gcrypt.Ludovic Courtès2020-12-15
| | | | | | | | Regression introduced in 6a060ff27ff68384d7c90076baa36c349fff689d. Reported by clone11 on #guix. * gnu/services/base.scm (references-file): Wrap gexp in 'with-extensions'.
* services: guix-publish: Depend on 'avahi-daemon' when needed.Ludovic Courtès2020-12-09
| | | | | | * gnu/services/base.scm (guix-publish-shepherd-service): Add 'user-processes' to 'requirement'. When ADVERTISE? is true, also add 'avahi-daemon'.
* service: Add shepherd discover action.Mathieu Othacehe2020-12-07
| | | | | | | * gnu/services/base.scm (shepherd-discover-action): New procedure, (guix-shepherd-service)[<actions>]: add it, [<start>]: honor it. * doc/guix.texi (Invoking guix-daemon): Document it.
* Use substitute servers on the local network.Mathieu Othacehe2020-11-29
| | | | | | | | | | | | | | | * guix/scripts/discover.scm: New file. * Makefile.am (MODULES): Add it. * nix/nix-daemon/guix-daemon.cc (options): Add "discover" option, (parse-opt): parse it, (main): start "guix discover" process when the option is set. * guix/scripts/substitute.scm (%local-substitute-urls): New variable, (substitute-urls): add it. * gnu/services/base.scm (<guix-configuration>): Add "discover?" field, (guix-shepherd-service): honor it. * doc/guix.texi (Invoking guix-daemon): Document "discover" option, (Base Services): ditto.
* publish: Add advertising support.Mathieu Othacehe2020-11-29
| | | | | | | | | | | | | * guix/scripts/publish.scm (%options): Add "--advertise" option. (show-help): Document it. (service-name): New procedure, (publish-service-type): new variable. (run-publish-server): Add "advertise?" and "port" parameters. Use them to publish the server using Avahi. (guix-publish): Pass the "advertise?" option to "run-publish-server". * gnu/services/base.scm (<guix-publish-configuration>): Add "advertise?" field. (guix-publish-shepherd-service): Honor it.
* mapped-devices: Allow target to be list of strings.Mikhail Tsykalov2020-11-26
| | | | | | | | | | | * gnu/system/mapped-devices.scm (<mapped-device>): Rename constructor to %mapped-device. [target]: Remove field. [targets]: New field. Adjust users. (mapped-device-compatibility-helper, mapped-device): New macros. (mapped-device-target): New deprecated procedure. Signed-off-by: Ludovic Courtès <ludo@gnu.org>
* Merge branch 'version-1.2.0' into master.Maxim Cournoyer2020-11-20
|\
| * services: base: Re-export %default-substitute-urls from (guix store).Marius Bakke2020-11-18
| | | | | | | | * gnu/services/base.scm: Export %DEFAULT-SUBSTITUTE-URLS.
* | Merge remote-tracking branch 'upstream/version-1.2.0'Tobias Geerinckx-Rice2020-11-18
|\|