Commit Graph

584 Commits

Author SHA1 Message Date
Clément Lassieur 750a423996
services: shepherd: Replace spaces with hyphens in file names.
This fixes a bug whereby names of files defining services would be
invalid if 'provisions' contained more than one element.

* gnu/services/shepherd.scm (shepherd-service-file-name): Update
'match-lambda' accordingly.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2017-02-08 16:17:05 +01:00
Ludovic Courtès 387e175492
services: Add 'special-files-service-type'.
* gnu/build/activation.scm (activate-/bin/sh): Remove.
(activate-special-files): New procedure.
* gnu/services.scm (activation-script): Remove call to
'activate-/bin/sh'.
(special-files-service-type): New variable.
(extra-special-file): New procedure.
* gnu/services/base.scm (%base-services): Add SPECIAL-FILES-SERVICE-TYPE
instance.
* gnu/tests/base.scm (run-basic-test)[special-files]: New variables.
["special files"]: New test.
2017-02-08 16:17:05 +01:00
Ludovic Courtès a062b6ca99
services: bitlbee: Run in a container.
* gnu/services/networking.scm (bitlbee-shepherd-service): Wrap in
'with-imported-modules' and add 'modules' field.  Use
'make-forkexec-constructor/container' and pass #:mappings.
2017-02-07 00:08:11 +01:00
Ludovic Courtès b9a5efa596
services: bitlbee: Read the PID file.
* gnu/services/networking.scm (bitlbee-shepherd-service): Pass
  #:pid-file to 'make-forkexec-constructor'.
2017-02-07 00:08:10 +01:00
Mathieu Othacehe eb122280a0
services: cuirass: Add load-path to cuirass configuration
* gnu/services/cuirass.scm (<cuirass-configuration>): Add load-path field.
(cuirass-shepherd-service): Honor it.
* doc/guix.texi (Continuous Integration): Document it.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2017-02-02 09:04:40 +01:00
Ludovic Courtès 8de3e4b35f
services: Make 'static-networking' extensible.
This allows users to statically define several interfaces.

* gnu/services/networking.scm (<static-networking>)[provision]
[name-servers]: Add default values.
(static-networking-shepherd-service)
(static-networking-etc-files)
(static-networking-shepherd-services): New procedures.
(static-networking-service-type): Change to extend both
SHEPHERD-ROOT-SERVICE-TYPE and ETC-SERVICE-TYPE.
(static-networking-service): Remove default value of #:provision.
Implement using 'simple-service'.
* gnu/services/base.scm (%base-services): Replace
'static-networking-service' call with 'service' form.
* doc/guix.texi (Networking Services): Update documentation.
2017-02-01 23:53:35 +01:00
Ludovic Courtès a43aca973e
system: Introduce 'file-systems' Shepherd service.
* gnu/services/base.scm (file-system-shepherd-services): New procedure.
(file-system-service-type): Use it as the SHEPHERD-ROOT-SERVICE-TYPE
extension.
(user-processes-service-type): Change to take a single 'grace-delay'
parameter.
(user-processes-service): Remove 'file-systems' parameter.  Pass
GRACE-DELAY as the only value for the service.
* gnu/system.scm (essential-services): Adjust accordingly.
2017-01-31 23:21:59 +01:00
Mathieu Othacehe 70dfa4e07a
services: Export guix-configuration getters.
* gnu/services/base.scm (guix-configuration-*): Export.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2017-01-25 19:04:21 +01:00
Clément Lassieur e57bd0bed8
services: Fix 'mkdir-p' in activation scripts.
* gnu/services/cups.scm (%cups-activation): Import (guix build utils).
* gnu/services/mail.scm (opensmtpd-activation): Idem.
* gnu/services/networking.scm (ntp-service-activation): Idem.
* gnu/services/spice.scm (spice-vdagent-activation): Idem.
* gnu/services/ssh.scm (openssh-activation): Idem.
  (dropbear-activation): Idem.
* gnu/services/vpn.scm (%openvpn-activation): Idem.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2017-01-25 14:05:37 +01:00
Clément Lassieur 87508d9a0b
services: prosody: Fix activation script.
* gnu/services/messaging.scm (prosody-activation): Import (guix build utils)
  for 'mkdir-p'.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2017-01-23 15:20:04 +01:00
Mathieu Othacehe 11b7717deb
services: cuirass: Add port to cuirass configuration
* gnu/services/cuirass.scm (<cuirass-configuration>): Add port field.
(cuirass-shepherd-service): Honor it.
* doc/guix.texi (Continuous Integration): Document it.

Signed-off-by: Mathieu Lirzin <mthl@gnu.org>
2017-01-22 23:51:56 +01:00
Ludovic Courtès be051880c4
services: Reindent vpn.scm.
This fixes indentation of 'match' forms.

* gnu/services/vpn.scm: Pass through 'indent-code.el'.
2017-01-20 21:39:17 +01:00
Christopher Baines b726096bc5
services: network-manager: Use record for configuration.
* gnu/services/network-manager.scm (<network-manager-configuration>): New
record type.
(network-manager-shpeherd-service): Change to use the
network-manager-configuration record, rather than a package.  Generate a
simple configuration file from the network-manager-configuration record.
(network-manager-service-type): Update extensions to take the
network-manager-configuration rather than a package.
(network-manager-service): Remove function, the network-manager-service-type
can be used instead, and this avoids keeping the function signature and value
coresponding to the service type in sync.
* doc/guix.texi (Networking Services): Remove documentation for the removed
network-manager-service procedure, and add documentation of the
network-manager-service-type variable and network-manager-configuration
record.

Signed-off-by: 宋文武 <iyzsong@member.fsf.org>
2017-01-20 21:45:56 +08:00
Ludovic Courtès dc72a7f7f7
services: nginx: Add default values for <nginx-configuration> fields.
* gnu/services/web.scm (<nginx-configuration>)[nginx, log-directory]
[run-directory, server-blocks, upstream-blocks, file]: Add default
values.
2017-01-19 14:44:59 +01:00
Christopher Baines 9c557a69ae
services: nginx: Add support for 'location' blocks.
* gnu/services/web.scm (<nginx-server-configuration>): Add field 'locations'.
(<nginx-location-configuration>): New record type.
(<nginx-named-location-configuration>): New record type.
(nginx-location-config): New function.
(default-nginx-server-config): Include locations.
* doc/guix.texi (Web Services): Document the new nginx-location-configuration
and nginx-named-location-configuration data types, as well as the changes to
the nginx-server-configuration.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2017-01-19 14:44:59 +01:00
Christopher Baines cb341293fa
services: nginx: Add support the 'upstream' module.
* gnu/services/web.scm (<nginx-upstream-configuration>): New record type.
(<nginx-configuration>): Add new field upstream-blocks.
(nginx-upstream): New function.
(default-nginx-config): Add upstream-list parameter.
(nginx-service): Add optional upstream list keyword argument.
* doc/guix.texi (Web Services): Document the new nginx-upstream-configuration
data type and changes to the nginx function.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2017-01-19 14:44:59 +01:00
Julien Lepiller 2be1b4712d
gnu: Add openvpn service.
* gnu/services/vpn.scm: New file.
* gnu/local.mk (GNU_SYSTEM_MODULES): Add it.
* doc/guix.texi (VPN Services): New section.
2017-01-15 12:24:52 +01:00
Christopher Baines 67cadaca47
services: Add 'redis-service-type'.
* gnu/services/database.scm (<redis-configuration>): New record type.
(%redis-accounts, redis-service-type): New variables.
(default-redis.conf, redis-activation, redis-shepherd-service): New
procedures.
* doc/guix.texi (Database Services): Document the new redis service.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2017-01-12 16:49:47 +01:00
Ludovic Courtès 69323016d3
services: wicd: Create /var/run/wpa_supplicant.
* gnu/services/networking.scm (%wicd-activation): Create
/var/run/wpa_supplicant.
2017-01-11 11:16:14 +01:00
Clément Lassieur 78cef99b98
gnu: Add Prosody service.
* gnu/services/messaging.scm: New file.
* gnu/services/configuration.scm: New exported procedures.
* gnu/local.mk (GNU_SYSTEM_MODULES): Add gnu/services/messaging.scm.
* doc/guix.texi (Messaging Services): New section.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2017-01-08 23:39:36 +01:00
Julien Lepiller d338237d8c
services: nginx: Make service extensible.
* gnu/services/web.scm (<nginx-configuration>)[server-blocks]: New
field.
(nginx-activation): When CONFIG-FILE is #f, use 'default-nginx-config'.
(nginx-shepherd-service): Likewise.
(nginx-service-type): Add 'compose' and 'extend' fields.
(nginx-service): Change default value of #:server-list to '(), and
default value of #:config-file to #f.
* doc/guix.texi (Web Services): Document it.

Co-authored-by: Ludovic Courtès <ludo@gnu.org>
2017-01-03 14:30:44 +01:00
Julien Lepiller 4e9ae301ce
services: nginx: Fix multiple index and server name.
* gnu/services/web.scm (config-domain-strings, config-index-string): separate
names with a space.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2017-01-03 14:30:44 +01:00
Julien Lepiller 3b9b12ef49
services: nginx: Rename "vhost" to "server".
* gnu/services/web.scm (<nginx-vhost-configuration>): Rename to...
(<nginx-server-configuration>): ... this.
* doc/guix.texi (Web Services): Adjust accordingly.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2017-01-03 14:30:44 +01:00
Ludovic Courtès 231eddc88a
services: cuirass: Remove 'cuirass-service' procedure.
* gnu/services/cuirass.scm (<cuirass-configuration>)[specifications]:
Remove default value.
(cuirass-service): Remove.
* doc/guix.texi (Continuous Integration): Adjust accordingly.
2017-01-01 23:30:31 +01:00
Ludovic Courtès 8de938d59a
services: cuirass: Allow for gexps in specifications.
* gnu/services/cuirass.scm (<cuirass-configuration>)[specifications]:
Change default value to #~'().
(cuirass-shepherd-service): Remove conditional for "--specifications".
Use 'scheme-file' instead of 'plain-file'.  Change file name to
"cuirass-specs.scm".
* doc/guix.texi (Continuous Integration): Change the example to use a
gexp where #:file refers to a file within Cuirass.  Adjust
documentation.
2017-01-01 23:30:30 +01:00
Ludovic Courtès 3547a5effe
services: Add libmtp's udev rules to '%desktop-services'.
Suggested by Chris Marusich <cmmarusich@gmail.com>.

* gnu/services/desktop.scm (%desktop-services): Add 'mtp' service via
call to 'simple-service'.
2016-12-29 23:35:42 +01:00
John Darrington d1f3063196
gnu: Fix typo in comment.
* gnu/services/sddm.scm: Fix typo.
2016-12-21 20:45:34 +01:00
Ludovic Courtès 38d6aa05e2
services: cuirass: Add Cuirass to the system profile.
* gnu/services/cuirass.scm (cuirass-service-type): Extend
PROFILE-SERVICE-TYPE.
2016-12-20 10:27:08 +01:00
Ludovic Courtès 379b6ba5a9
services: cuirass: Add 'cuirass' field.
* gnu/services/cuirass.scm (<cuirass-configuration>)[cuirass]: New
field.
(cuirass-shepherd-service): Honor it.
* doc/guix.texi (Continuous Integration): Document it.
2016-12-20 10:27:08 +01:00
Ludovic Courtès 137f8df66c
services: cuirass: Create the database directory.
* gnu/services/cuirass.scm (cuirass-activation): Create the database
directory for CONFIG.
2016-12-20 10:27:08 +01:00
Ludovic Courtès dc0ef095b3
services: guix: Add 'log-file' configuration option.
* gnu/services/base.scm (<guix-configuration>)[log-file]: New field.
(guix-shepherd-service): Pass #:log-file to 'make-forkexec-constructor'.
* gnu/services/admin.scm (simple-rotation-config): Take a list of
files and join them with commas.
(%default-rotations): Add /var/log/guix-daemon.log.
* doc/guix.texi (Base Services): Document it.
2016-12-19 23:57:20 +01:00
Ludovic Courtès f78903f363
services: guix: Remove dependency on lsh.
* gnu/services/base.scm (<guix-configuration>)[lsh]: Remove.
(guix-shepherd-service): Remove lsh from 'PATH'.
* doc/guix.texi (Base Services): Adjust accordingly.
2016-12-19 23:57:19 +01:00
Ludovic Courtès 463995da0c
services: cuirass: Cache defaults to /var/cache/cuirass.
The previous default value depended on the 'HOME' environment variable,
which happened to be unset.  Thus, /.cache was being used.

* gnu/services/cuirass.scm (<cuirass-configuration>)[cache-directory]:
Change default value to "/var/cache/cuirass".
(cuirass-shepherd-service): Always pass "--cache-directory".
(cuirass-activation): New procedure.
(cuirass-service-type): Use it as an extension to
ACTIVATION-SERVICE-TYPE.
* doc/guix.texi (Continuous Integration): Adjust accordingly.
2016-12-19 23:57:19 +01:00
Ludovic Courtès 831071b84f
services: cuirass: Honor 'user' and 'group'.
* gnu/services/cuirass.scm (cuirass-shepherd-service): Pass the user and
group of CONFIG to 'make-forkexec-constructor'.
2016-12-19 23:57:19 +01:00
Ludovic Courtès b17e326f17
services: cuirass: Add 'log-file' option.
* gnu/services/cuirass.scm (<cuirass-configuration>)[log-file]: New
field.
(cuirass-shepherd-service): Pass it to 'make-forkexec-constructor'.
2016-12-19 23:57:19 +01:00
Ludovic Courtès 9fc037fe10
services: Use 'file-append' in more places.
* gnu/services/avahi.scm (avahi-shepherd-service): Use #$(file-append x y)
instead of (string-append #$x y).
* gnu/services/base.scm (unicode-start)
(console-keymap-service-type, console-font-shepherd-services)
(mingetty-shepherd-service, nscd-shepherd-service)
(hydra-key-authorization, guix-shepherd-service)
(guix-publish-shepherd-service, udev-shepherd-service)
(gpm-shepherd-service, <kmscon-configuration>)
(kmscon-service-type): Likewise.
* gnu/services/shepherd.scm (shepherd-boot-gexp): Likewise.
2016-12-19 17:51:00 +01:00
Mathieu Lirzin 57aa94bd7e
services: cuirass: Put specifications in the store.
* gnu/services/cuirass.scm (<cuirass-configuration>): Change type of
'specifications' field to an alist to match the documentation example.
(cuirass-shepherd-service): Store the provided specifications in a file.  Use
that file as the "--specification" argument.
2016-12-15 22:50:27 +01:00
Christopher Baines e05b780a58
services: postgresql: Add locale to configuration
* gnu/services/databases.scm (<postgresql-configuration>): Add locale
  field.
  (postgresql-shepherd-service): Pass locale to initdb.
  (postgresql-service): Add locale default.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2016-12-15 16:55:02 +01:00
Christopher Baines 2d3d5cc5ea
services: postgresql: Add port to configuration
* gnu/services/databases.scm (<postgresql-configuration>): Add port
  field.
  (postgresql-shepherd-service): Pass port to postgres.
  (postgresql-service): Add port default.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2016-12-15 16:54:22 +01:00
Christopher Baines 4b41febf9c
services: mysql: Add port to configuration
* gnu/services/databases.scm (<mysql-configuration>): Add port field.
(mysql-configuration-file): Use the port field when creating the
configuration file.
* doc/guix.texi (Database Services): Document it.

Co-authored-by: Ludovic Courtès <ludo@gnu.org>
2016-12-14 00:22:49 +01:00
Ludovic Courtès 9328eafbf5
services: file-system: Make sure fsck.* commands are in $PATH.
Fixes a regression introduced in
bf7ef1bb84, whereby the fsck.* commands
would not be found.

* gnu/services/base.scm (file-system-shepherd-service): Call calls to
'setenv'.
2016-12-05 20:54:59 +01:00
Ludovic Courtès ba9f0db08c
services: tor: Make sure /var/lib is world-readable.
* gnu/services/networking.scm (tor-hidden-service-activation): Add
'chmod' call for /var/lib.
2016-12-04 22:32:25 +01:00
John Darrington 8e3f813f22
gnu: Add Kerberos client service.
* doc/guix.texi (Kerberos Services)[Krb5 Service]: New subsubheading.
* gnu/services/kerberos.scm (krb5-service-type): New variable.
* gnu/services/configuration.scm (configuration-field-serializer,
  configuration-field-getter): Export variables.
2016-12-03 18:00:32 +01:00
John Darrington bf7ef1bb84
gnu: file-system-shepherd-service: Use mount-file-system.
* gnu/services/base.scm (file-system-shepherd-service): Use
  mount-file-system instead of manually mounting the file system.
2016-12-02 17:43:30 +01:00
Andy Patterson 4ce8860df9
services: cups: Follow symlinks when installing extensions.
* gnu/services/cups.scm (union-directory): Use "stat" when calling
"find-files" to follow symlinks.
2016-12-01 11:03:20 +01:00
Ricardo Wurmus 819c1945d1
services: nginx: Join strings with spaces.
* gnu/services/web.scm (config-domain-strings, config-index-strings):
Use "string-join" to join strings with spaces.
2016-11-30 16:03:18 +01:00
Mathieu Lirzin a7cf4eb6d9
services: Add 'cuirass-service'.
* gnu/services/cuirass.scm: New file.
* gnu/local.mk (GNU_SYSTEM_MODULES): Add it.
* doc/guix.texi (Continuous integration): New node.
2016-11-29 23:13:11 +01:00
Julien Lepiller 5305ed2002
services: Factorize configuration abstraction.
* gnu/services/mail.scm and gnu/services/cups.scm (&configuration-error)
(configuration-error, configuration-field-error)
(configuration-missing-field, configuration-field, serialize-configuration)
(validate-configuration, define-configuration, uglify-field-name)
(serialize-field, serialize-package, serialize-string)
(serialize-space-separated-string-list, space-separated-string-list?)
(serialize-file-name, file-name?, serialize-field-name)
(generate-documentation): Move duplicate code...
* gnu/services/configuration.scm: ...to this new file.
* gnu/local.mk (GNU_SYSTEM_MODULES): Add configuration.scm.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2016-11-26 19:46:01 +01:00
John Darrington fc5dc4e81c
gnu: Whitespace changes
* gnu/services/kerberos.scm: Fold lines to 80 character limit.
2016-11-26 07:37:33 +01:00
宋文武 f88371e866
services: Add opensmtpd service.
* gnu/services/mail.scm (<opensmtpd-configuration>): New record type.
(%default-opensmtpd-config-file, %opensmtpd-accounts): New variables.
(opensmtpd-shepherd-service, opensmtpd-activation): New procedures.
(opensmtpd-service-type): New variable.
* doc/guix.texi (Mail Services): Document it.
2016-11-26 12:50:11 +08:00
Ludovic Courtès 030f59fac9
services: network-manager: Depend on 'wpa-supplicant'.
Suggested by Chris Marusich <cmmarusich@gmail.com>.

* gnu/services/networking.scm (network-manager-shepherd-service)
[requirement]: Add 'wpa-supplicant'.
2016-11-24 21:43:48 +01:00
Ludovic Courtès 89007a0bb7
services: network-manager: Install polkit actions.
Reported by Chris Marusich <cmmarusich@gmail.com>
at <https://lists.gnu.org/archive/html/help-guix/2016-11/msg00038.html>.

* gnu/services/networking.scm (network-manager-service-type)[extensions]:
Add POLKIT-SERVICE-TYPE.
2016-11-24 21:43:47 +01:00
Ludovic Courtès 2e32869824
services: Move polkit to (gnu services dbus).
* gnu/services/desktop.scm (<polkit-configuration>, %polkit-accounts)
(%polkit-pam-services, polkit-directory, polkit-etc-files)
(polkit-setuid-programs, polkit-service-type, polkit-service): Move
to...
* gnu/services/dbus.scm: ... here.
2016-11-24 21:43:47 +01:00
Ludovic Courtès b3131e2318
services: static-networking: Remove unused parameter.
This is a followup to e48fcd7b8d.

* gnu/services/networking.scm (static-networking-service): Remove #:net-tools.
(static-networking-service-type): Remove outdated comment.
2016-11-21 15:25:38 +01:00
ng0 e01e2c6c52
gnu: services: Add git-service.
* gnu/services/version-control.scm: New file.
* gnu/local.mk (GNU_SYSTEM_MODULES): Add it.
* doc/guix.texi (Misellaneous Services)[Version Control]: New section.

Co-authored-by: 宋文武 <iyzsong@member.fsf.org>
2016-11-21 20:37:43 +08:00
Ludovic Courtès e48fcd7b8d
services: static-networking: Avoid use of net-tools.
* gnu/services/networking.scm (<static-networking>)[net-tools]: Remove.
(static-networking-service-type): Use 'add-network-route/gateway' and
'delete-network-route' instead of NET-TOOLS.
(static-networking-service): Adjust accordingly.
2016-11-21 00:34:49 +01:00
宋文武 e5aade794a
services: dicod-service: Honor 'dicod-configuration-dico'.
* gnu/services/dict.scm (dicod-shepherd-service): Use
'dicod-configuration-dico' of config.
2016-11-19 19:37:30 +08:00
Ludovic Courtès 1f9803c2a4
services: static-networking: Add netmask.
Reported by Mathieu Lirzin and Andreas Enge.

* gnu/services/networking.scm (<static-networking>)[netmask]: New
field.
(static-networking-service-type): Honor it.
* gnu/services/networking.scm (static-networking-service): Add #:netmask
and honor it.
* doc/guix.texi (Networking Services): Adjust accordingly.
2016-11-17 23:21:48 +01:00
Tomáš Čech e25c904f2c
services: Require wpa-supplicant-service for connman-service.
* gnu/services/networking.scm (connman-shepherd-service): Add
  wpa-supplicant among list of requirements.
2016-11-15 00:19:23 +01:00
Tomáš Čech 2cccbc2af2
services: Add wpa-supplicant-service.
* gnu/services/networking.scm (wpa-supplicant-service): New procedure.
(wpa-supplicant-service-type): New variable.
* doc/guix.texi (Networking Services): Document it.
2016-11-15 00:19:17 +01:00
Ludovic Courtès 2cab1dd58b
Merge branch 'core-updates' 2016-11-13 00:34:16 +01:00
John Darrington 859e367d07
gnu: Add pam-krb5 service.
* doc/guix.texi (Kerberos Services): New node.
* gnu/services/kerberos.scm: New file.
* gnu/local.mk: Add it.
2016-11-08 21:35:26 +01:00
Leo Famulari 02c73adcdf
Merge branch 'master' into core-updates 2016-10-26 19:00:06 -04:00
Julien Lepiller 8c00b83818
services: nginx: Virtual hosts are first-class configuration items.
* gnu/services/web.scm (<nginx-vhost-configuration>): New record type.
(config-domain-strings): New procedure.
(config-index-strings): New procedure.
(default-nginx-vhost-config): New procedure.
(default-nginx-config): Add vhost support and temporary directories
(nginx-activation): Create temporary directories
(nginx-service): Add vhost-list key.
* doc/guix.texi (Web Services): Document 'nginx-vhost-configuration'.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2016-10-24 22:50:40 +02:00
Mark H Weaver ca0635b4ba
Merge branch 'master' into core-updates 2016-10-23 14:16:39 -04:00
Ludovic Courtès dc0322b511
services: ntpd: Add 'allow-large-adjustment?' knob.
Suggested by Leo Famulari.

* gnu/services/networking.scm (<ntp-configuration>)[allow-large-adjustment?]:
New field.
(ntp-shepherd-service): Honor it.
(ntp-service): Add #:allow-large-adjustment? and honor it.
* doc/guix.texi (Networking Services): Document it.
2016-10-20 15:43:59 +02:00
Mark H Weaver dcaf70897a
Merge branch 'master' into core-updates 2016-10-17 16:47:12 -04:00
John Darrington 6f30a55c96
gnu: services sddm Fix typo.
* gnu/services/sddm.scm: sddm-confiugration? --> sddm-configuration?
2016-10-15 16:35:04 +02:00
Mark H Weaver 061d7f3bd2
Merge branch 'master' into core-updates 2016-10-13 05:53:07 -04:00
Andy Wingo f2ec23d18e
gnu: Add CUPS service.
* gnu/services/cups.scm: New file.
* gnu/local.mk (GNU_SYSTEM_MODULES): Add gnu/services/cups.scm.
* doc/guix.texi (Printing Services): New section.
2016-10-13 11:37:25 +02:00
John Darrington eb419bc9fe
gnu: Add NFS related services.
* gnu/services/nfs.scm (pipefs-service-type): New variable,
(gss-service-type): New variable, (idmap-service-type) New variable.

* doc/guix.texi (Network File System): New node.
2016-10-12 19:26:10 +02:00
8p8c 3126fd8820
services: xorg: Add ATI video driver to the default modules.
* gnu/services/xorg.scm (%default-xorg-modules): Add xf86-video-ati.

Signed-off-by: 宋文武 <iyzsong@gmail.com>
2016-10-06 20:46:50 +08:00
Ludovic Courtès 26cfc415be
services: rottlog: Add Rottlog to the global profile.
* gnu/services/admin.scm (rottlog-service-type): Extend
PROFILE-SERVICE-TYPE.
2016-10-03 14:48:44 +02:00
Ludovic Courtès 4d67ed70a3
services: rottlog: Improve default weekly rotations.
* gnu/services/admin.scm (%rotated-files): Add "/var/log/maillog".
(syslog-rotation-config): Change parameter to 'files'.  Return a
string-append gexp for all of FILES.
(simple-rotation-config): Remove unnecessary 'postrotate' and
'endscript'.
(%default-rotations): Adjust accordingly.
2016-10-03 14:47:55 +02:00
Ludovic Courtès d8f3128119
services: openssh-service-type: Expose 'openssh-configuration'.
* gnu/services/ssh.scm (<openssh-configuration>): Add default values.
[pubkey-authentication?]: Rename to...
[public-key-authentication?]: ... this.
(openssh-service): Remove.
* doc/guix.texi (Networking Services): Adjust accordingly.
2016-10-03 00:38:28 +02:00
Jan Nieuwenhuizen 92c03a8715
services: Add rottlog.
* gnu/services/admin.scm: New file.
* gnu/local.mk (GNU_SYSTEM_MODULES): Add it.
* doc/guix.texi (Log Rotation): New node.

Co-authored-by: Ludovic Courtès <ludo@gnu.org>
2016-10-03 00:38:28 +02:00
John Darrington 43f7af428e
gnu: rpcbind-configuration: Rename pkg to nfs-utils
* gnu/services/nfs.scm (<rpcbind-configuration>): "pkg" --> "nfs-utils"
2016-10-01 09:26:07 +02:00
Julien Lepiller 86d8f6d3ef
services: Add 'openssh-service'.
* gnu/packages/ssh.scm (openssh)[arguments]: Set sysconfdir to /etc/ssh.
* gnu/services/ssh.scm (<openssh-configuration>): New record type.
(%openssh-accounts): New variable.
(openssh-activation, openssh-config-file, openssh-shepherd-service)
(openssh-service): New procedures.
(openssh-service-type): New variable.
* doc/guix.texi (Networking Services): Document 'openssh-services'.

Co-authored-by: Ludovic Courtès <ludo@gnu.org>
2016-09-29 23:11:48 +02:00
Andy Wingo 66329c23a1
gnu: New default Dovecot service postmaster_address
* gnu/services/mail.scm (dovecot-configuration): Change default for
  postmaster-address, as dovecot is now requiring a non-empty value and
  will fail to start up otherwise.
* doc/guix.texi (Mail Services): Update.
2016-09-27 14:45:07 +02:00
Ludovic Courtès 4a84a48742
services: console-font: A single service handles all the VTs.
* gnu/services/base.scm (%default-console-font): New variable.
(console-font-shepherd-services): New procedure.
(console-font-service-type): Change to use 'service-type'.
(console-font-service): Rewrite using 'simple-service'.
(%base-services): Use a single CONSOLE-FONT-SERVICE-TYPE instance.
* gnu/system/install.scm (installation-services): Likewise.
2016-09-19 23:36:17 +09:00
John Darrington 8f65585b14
doc: "filesystem" -> "file system"
* doc/guix.texi: "filesystem" -> "file system"
* gnu/packages/admin.scm: "filesystem" -> "file system"
* gnu/packages/cdrom.scm: "filesystem" -> "file system"
* gnu/packages/compression.scm: "filesystem" -> "file system"
* gnu/packages/disk.scm: "filesystem" -> "file system"
* gnu/packages/gnome.scm: "filesystem" -> "file system"
* gnu/packages/irc.scm: "filesystem" -> "file system"
* gnu/packages/linux.scm: "filesystem" -> "file system"
* gnu/packages/mail.scm: "filesystem" -> "file system"
* gnu/packages/mpd.scm: "filesystem" -> "file system"
* gnu/packages/ocaml.scm: "filesystem" -> "file system"
* gnu/packages/perl.scm: "filesystem" -> "file system"
* gnu/packages/python.scm: "filesystem" -> "file system"
* gnu/packages/search.scm: "filesystem" -> "file system"
* gnu/packages/tls.scm: "filesystem" -> "file system"
* gnu/services/mail.scm: "filesystem" -> "file system"
2016-09-16 18:16:13 +02:00
Tobias Geerinckx-Rice d21047d504
services: nginx: Actually check if configuration is valid.
* gnu/services/web.scm (nginx-activation): Fix path to nginx binary.
2016-09-13 16:48:44 +02:00
David Craven 46ec2707a4
services: Add kmscon service.
* gnu/services/base.scm (<kmscon-configuration>, kmscon-service-type):
  New variables.
* doc/guix.texi (@deffn kmscon-service-type, @deftp
  kmscon-configuration): Add documentation.
2016-09-11 16:29:45 +02:00
David Craven 317d3b474a
services: Add login-service.
* gnu/services/base.scm (%default-motd, <login-configuration>,
  login-pam-service, login-serivce-type, login-service): New variables.
  (<mingetty-configuration>, mingetty-shepherd-service,
  mingetty-serivce-type): Remove motd. Remove allow-empty-passwords?.
  Remove mingetty-pam-service.
  (%base-services): Add login-service. Remove motd.
2016-09-11 16:29:45 +02:00
Ludovic Courtès 9e41130b14
system: Use 'file-append' to denote file names.
* gnu/services/avahi.scm, gnu/services/base.scm,
gnu/services/databases.scm, gnu/services/dbus.scm,
gnu/services/desktop.scm, gnu/services/dict.scm,
gnu/services/mail.scm, gnu/services/networking.scm,
gnu/services/sddm.scm, gnu/services/spice.scm,
gnu/services/ssh.scm, gnu/services/web.scm,
gnu/services/xorg.scm, gnu/system.scm: Replace the
 #~(string-append #$pkg "/bin/foo") idiom with
 (file-append pkg "/bin/foo").
2016-09-10 13:10:06 +02:00
John Darrington 1c6c0ad067
services: ntpd: Use a dedicated directory for drift file.
Fixes <https://bugs.gnu.org/24366>.  Drift file now resides in a
dedicated directory owned by the daemon.

* gnu/services/networking.scm (ntp-service-activation): New procedure,
(ntp-service-type): Add new service-extension.
2016-09-08 18:08:22 +02:00
John Darrington d6a07ee675
gnu: Add rpc-daemon service
* gnu/services/nfs.scm: New file.
* gnu/local.mk (GNU_SYSTEM_MODULES): Add it.
2016-09-07 20:26:11 +02:00
Ludovic Courtès afa54a38b7
services: syslog: Use a PID file.
* gnu/services/base.scm (syslog-service-type)[start]: Remove --no-detach
and use #:pid-file.
2016-09-07 11:49:48 +02:00
David Craven 935644c01a
services: Add sddm service.
* gnu/services/sddm.scm: New file.
* gnu/local.mk (GNU_SYSTEM_MODULES): Add it.
* doc/guix.texi (@deftp, @deffn): Add documentation.
2016-09-06 17:48:59 +02:00
David Craven ec2e2f6ce2
services: syslog: Use syslog-configuration.
* gnu/services/base.scm (<syslog-configuration>): New variable.
  (syslog-service-type): Use <syslog-configuration>.
  (syslog-service): Use <syslog-configuration>.
* gnu/tests/base.scm (%avahi-os): Use <syslog-configuration>.
* doc/guix.texi (syslog-configuration-type): Add @deftp.
  (syslog-service): Update @deffn.
2016-09-06 17:48:59 +02:00
David Craven f2901d824a
services: Export initrc.
* gnu/services/xorg.scm (define-module): Export initrc.
2016-09-06 17:48:59 +02:00
John Darrington 705b971477
gnu: Fix typo in description of xfce-desktop-service.
* gnu/services/desktop.scm (xfce-desktop-service) abilit --> ability.
2016-09-01 17:55:49 +02:00
Ludovic Courtès 38c2b50354
Reinstate "services: elogind: Provide '%elogind-file-systems' by extension."
This reverts commit 17073dafc5.
2016-09-01 14:57:03 +02:00
Marius Bakke 5fd66a37d5
gnu: slim: Move to display-managers.scm.
* gnu/packages/display-managers.scm: New file.
* gnu/packages/slim.scm: Delete file.
* gnu/local.mk (GNU_SYSTEM_MODULES): Adjust accordingly.
* gnu/services/xorg.scm: Likewise.
2016-09-01 14:36:49 +02:00
Ludovic Courtès 7b44cae50a
services: shepherd: Add 'shepherd-service-upgrade', from 'guix system'.
* guix/scripts/system.scm (service-upgrade): Move to...
* gnu/services/shepherd.scm (shepherd-service-upgrade): ... here.
* tests/system.scm ("service-upgrade: nothing to do", "service-upgrade:
one unchanged, one upgraded, one new", "service-upgrade: service
depended on is not unloaded", "service-upgrade: obsolete services that
depend on each other"): Move to...
* tests/services.scm: ... here.  Adjust to 'service-upgrade' rename.
2016-08-31 15:44:20 +02:00
Ludovic Courtès 6673bddc9a
services: shepherd: Parameterize 'shepherd-service-back-edges'.
* gnu/services/shepherd.scm (shepherd-service-back-edges): Add
  #:provision and #:requirement parameter.  Honor them.
2016-08-31 15:44:20 +02:00
Ludovic Courtès a5d78eb64b
services: shepherd: Add 'shepherd-service-lookup-procedure'.
* gnu/services/shepherd.scm (shepherd-service-lookup-procedure): New
procedure.
(shepherd-service-back-edges)[provision->service]: Use it.
* tests/services.scm ("shepherd-service-lookup-procedure"): New test.
2016-08-31 15:44:20 +02:00
Ludovic Courtès 183605c853
services: herd: Provide <live-service> objects.
* gnu/services/herd.scm (<live-service>): New record type.
(current-services): Change to return a single value: #f or a list of
<live-service>.
* guix/scripts/system.scm (call-with-service-upgrade-info): Adjust
accordingly.
* gnu/tests/base.scm (run-basic-test)["shepherd services"]: Adjust
accordingly.
2016-08-31 15:44:19 +02:00
Mark H Weaver 17073dafc5
Revert "services: elogind: Provide '%elogind-file-systems' by extension."
This reverts commit 3cf319a3f8.
2016-08-22 08:16:37 -04:00
Ludovic Courtès 3cf319a3f8
services: elogind: Provide '%elogind-file-systems' by extension.
* gnu/system/file-systems.scm (%base-file-systems): Remove
%ELOGIND-FILE-SYSTEMS.
* gnu/services/desktop.scm (elogind-service-type): Extend
FILE-SYSTEM-SERVICE-TYPE to provide %ELOGIND-FILE-SYSTEMS.
2016-08-22 00:20:48 +02:00
Ludovic Courtès aa1145df8d
services: Make a single extensible 'file-systems' service.
Previously we would create one 'file-system-service-type' instead per
file system.  Now, we create only one instance for all the file
systems.

* gnu/services/base.scm (fstab-service-type)[compose]: Change to
CONCATENATE.
(file-system-shepherd-service): Change to return either one
<shepherd-service> or #f.
(file-system-service-type): Pluralize 'name'.  Adjust
SHEPHERD-ROOT-SERVICE-TYPE extension to above changes.  Add 'compose'
and 'extend'.
(file-system-service): Remove.
* gnu/system.scm (other-file-system-services): Rename to...
(non-boot-file-system-service): ... this.  Change to return a single
FILE-SYSTEM-SERVICE-TYPE instance.
(essential-services): Adjust accordingly.
2016-08-22 00:20:48 +02:00
Ludovic Courtès 5b58c28b7e
services: guix: Add 'authorized-keys' configuration knob.
* gnu/services/base.scm (hydra-key-authorization): Add 'key' parameter
and honor it.
(%default-authorized-guix-keys): New variable.
(<guix-configuration>)[authorized-keys]: New field.
(guix-shepherd-service): Adjust 'match' clause accordingly.
(guix-activation): Adjust call to 'hydra-key-authorization'.
* doc/guix.texi (Base Services): Document 'authorized-keys'.
2016-08-19 09:11:00 +02:00
Mark H Weaver 5f4a446d37
services: guix: Fix activation when 'authorize-key?' is false.
* gnu/services/base.scm (guix-activation): Ensure that a gexp is
returned when 'authorize-key?' is false.
2016-08-14 02:48:51 -04:00
David Craven 00f4690568
services: Add spice vdagent service.
* gnu/services/spice.scm: New file.
* gnu/local.mk (GNU_SYSTEM_MODULES): Add it.
* doc/guix.texi (Various Services): New subheading.
2016-08-05 21:48:43 +02:00
Tomáš Čech 24e964314e
services: Export *-service-type and *-configuration.
This allows users to use 'modify-services' and similar constructs for
all these service types.

* gnu/services/avahi.scm: export avahi-configuration.
* gnu/services/base.scm: export gpm-configuration and
rngd-configuration.
* gnu/services/databases.scm: export *-service-type and *-configuration.
* gnu/services/dbus.scm: export dbus-configuration.
* gnu/services/dict.scm: export dicod-service-type.
* gnu/services/lirc.scm: export lirc-configuration and
lirc-service-type.
* gnu/services/mail.scm: export dovecot-service-type.
* gnu/services/web.scm: export nginx-configuration and
nginx-service-type.
* gnu/services/xorg.scm: export screen-locker and screen-locker?.
* gnu/services/ssh.scm: export lsh-configuration and lsh-service-type.
* gnu/services/desktop.scm: export *-service, *-service-type
and *-configuration.
* gnu/services/networking.scm: export *-configuration
and *-service-type.

Co-authored-by: Ludovic Courtès <ludo@gnu.org>
2016-07-21 18:53:27 +02:00
Ricardo Wurmus 909147e43f
services: Add pam-limits-service.
* gnu/system/pam.scm (<pam-limits-entry>): New record type.
(pam-limits-entry, pam-limits-entry->string): New procedures.
* gnu/services/base.scm (pam-limits-service-type): New variable.
(pam-limits-service): New procedure.
* doc/guix.texi (Base Services): Document it.
2016-07-19 23:50:03 +02:00
Ludovic Courtès 2c2ec261a8
services: shepherd: Clarify error message about missing service.
Suggested by Tobias Geerinckx-Rice <me@tobias.gr>.

* gnu/services/shepherd.scm (assert-valid-graph)[assert-satisfied-requirements]:
Clarify error message.
2016-07-19 00:07:12 +02:00
Ludovic Courtès b9bb50c608
services: dbus: Synchronize startup using dbus-daemon's PID file.
* gnu/services/dbus.scm (dbus-shepherd-service): Pass #:pid-file to
'make-forkexec-constructor'.
2016-07-16 14:41:39 +02:00
David Craven 71b0601a97
services: Add 'dropbear-service'.
* gnu/services/ssh.scm (<dropbear-configuration>): New record type.
(dropbear-activation, dropbear-shepherd-service, dropbear-service): New
procedures.
(dropbear-service-type): New variable.
* doc/guix.texi (Networking Services): Document it.

Co-authored-by: Ludovic Courtès <ludo@gnu.org>
2016-07-15 17:57:28 +02:00
David Craven 2102ae2e30
gnu: lsh: Move to (gnu packages ssh)
* gnu/packages/lsh.scm: Remove.  Move 'lsh and liboop' to...
* gnu/packages/ssh.scm (liboop, lsh): ... here.  New variables.
* gnu/services/ssh.scm, gnu/services/base.scm: Adjust accordingly.
* gnu/local.mk (GNU_SYSTEM_MODULES): Adjust accordingly.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2016-07-15 17:57:28 +02:00
Ludovic Courtès a91c3fc727
services: <shepherd-service> no longer has an 'imported-modules' field.
* gnu/services/shepherd.scm (<shepherd-service>)[imported-modules]:
Remove.
(%default-imported-modules): Make private.
(shepherd-service-file): Use 'with-imported-modules'.
(shepherd-configuration-file): Remove 'modules' and the calls to
'imported-modules' and 'compiled-modules'.  Use
'with-imported-modules' instead.
* doc/guix.texi (Shepherd Services): Adjust accordingly.
* gnu/services/base.scm (file-system-shepherd-service): Use
'with-imported-modules'.  Remove 'imported-modules' field.
* gnu/system/mapped-devices.scm (device-mapping-service-type): Remove
'imported-modules'.
(open-luks-device): Use 'with-imported-modules'.
* gnu/tests.scm (marionette-shepherd-service): Remove 'imported-modules'
field and use 'with-imported-modules'.
2016-07-12 22:47:08 +02:00
Ludovic Courtès 4ee96a7912
gnu: Switch to 'with-imported-modules'.
* gnu/services.scm (directory-union): Use 'with-imported-modules'
instead of the '#:modules' argument of 'computed-file'.
* gnu/services/base.scm (udev-rules-union): Likewise.
* gnu/services/dbus.scm (system-service-directory): Likewise.
* gnu/services/desktop.scm (wrapped-dbus-service):
(polkit-directory): Likewise.
* gnu/services/networking.scm (tor-configuration->torrc): Likewise.
* gnu/services/xorg.scm (xorg-configuration-directory): Likewise.
* gnu/system/install.scm (self-contained-tarball): Likewise.
* gnu/system/linux-container.scm (container-script): Likewise.
* gnu/system/linux-initrd.scm (expression->initrd): Likewise, and
remove #:modules parameter.
(flat-linux-module-directory): Use 'with-imported-modules'.
(base-initrd): Likewise.
* gnu/system/locale.scm (locale-directory): Likewise.
* gnu/system/shadow.scm (default-skeletons): Likewise.
* gnu/system/vm.scm (expression->derivation-in-linux-vm): Likewise.
* gnu/tests/base.scm (run-basic-test): Likewise.
* gnu/tests/install.scm (run-install): Likewise.
* doc/guix.texi (Initial RAM Disk): Update 'expression->initrd'
documentation.
2016-07-12 22:47:08 +02:00
ng0 6c12abbdb2
services: nginx: Fix typo.
* gnu/services/web.scm (nginx-service): Fix typo.

Signed-off-by: Leo Famulari <leo@famulari.name>
2016-07-07 20:42:58 -04:00
David Craven b58cbf9ac5
services: Add rngd-service.
* gnu/services/base.scm (<rngd-configuration>): New record type.
(rngd-service-type): New variable.
(rngd-service): New procedure.
* doc/guix.texi (Base Services): Document it.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2016-07-05 11:10:01 +02:00
Ludovic Courtès c8695f325d
services: avahi: Add #:debug? parameter.
* gnu/services/avahi.scm (<avahi-configuration>)[debug?]: New field.
(avahi-shepherd-service): Honor it.
(avahi-service): Add #:debug? and honor it.
* doc/guix.texi (Networking Services): Adjust accordingly.
2016-06-27 21:41:38 +02:00
Ludovic Courtès 194ccecf77
services: avahi: Pass --daemonize and check for the PID file.
This makes sure the service's 'start' finishes when avahi-daemon is
ready to process requests.

* gnu/services/avahi.scm (avahi-shepherd-service): Use --daemonize
instead of --syslog and add #:pid-file.
2016-06-27 21:41:38 +02:00
Ludovic Courtès 9009538d84
services: Export more service types.
* gnu/services/base.scm (syslog-service-type): Export.
(urandom-seed-service-type): Export.
2016-06-27 21:41:38 +02:00
Ludovic Courtès 04101d99ee
services: nscd: Wait for the PID file.
* gnu/services/base.scm (nscd-shepherd-service): Pass #:pid-file.
2016-06-27 21:41:38 +02:00
Ludovic Courtès c311089b0b
services: Add 'mcron-service'.
* gnu/services/mcron.scm: New file.
* gnu/local.mk (GNU_SYSTEM_MODULES): Add it.
* gnu/tests/base.scm (%mcron-os, %test-mcron): New variables.
(run-mcron-test): New procedure.
* doc/guix.texi (Scheduled Job Execution): New node.
2016-06-22 22:56:06 +02:00
宋文武 922e21f436
gnu: services: Add bluetooth-service.
* gnu/services/desktop.scm (bluetooth-shepherd-service)
(bluetooth-service): New Prodecures.
(bluetooth-service-type): New variable.
* doc/guix.text (Desktop Services): Document it.
2016-06-18 09:53:14 +08:00
Ludovic Courtès a1b484654a
services: dicod: Add 'interfaces' configuration field.
This makes 'dicod' listen on 'localhost' by default, whereas it was
previously listening on all the interfaces, which is not a good default
security-wise.

* gnu/services/dict.scm (<dicod-configuration>)[interfaces]: New field.
(dicod-configuration-file)[database->text]: New procedure, with code
formerly in 'dicod-configuration->text'.
[dicod-configuration->text]: Rename to...
[configuration->text]: ... this.  Honor 'interfaces'.
* doc/guix.texi (Various Services): Document 'interfaces'.
2016-06-17 11:14:18 +02:00
宋文武 6575183b2c
gnu: services: Add mysql-service.
* gnu/services/database.scm (<mysql-configuration>): New record type.
(%mysql-accounts, mysql-service-type): New variables.
(mysql-configuration-file, %mysql-activation, mysql-shepherd-services)
(mysql-services): New procedures.
* doc/guix.texi (Database Services): Document it.
2016-06-16 21:26:50 +08:00
宋文武 c3d38b2b9d
gnu: services: Add dicod-service.
* gnu/services/dict.scm: New file.
* gnu/local.mk (GNU_SYSTEM_MODULES): Add it.
* doc/guix.texi (Various Services): Document it.
2016-06-05 13:48:15 +08:00
Leo Famulari 71cb237a7d
services: urandom-seed: Refresh seed at boot.
* gnu/services/base.scm (urandom-seed-shepherd-service): Refresh the random
seed unconditionally at boot. Ensure directory structure for %random-seed-file
exists when shutting down.
(%urandom-seed-activation): Remove variable.
(urandom-seed-service-type): Remove deleted variable from list of extensions.
2016-06-05 00:06:26 -04:00
Leo Famulari 8fe5d95e66
services: urandom-seed: Set umask to 077 while shutting down.
* gnu/services/base.scm (urandom-seed-shepherd-service): Call 'umask'.
2016-05-31 00:03:10 -04:00
Leo Famulari a535e12226
services: Add urandom-seed-service.
Fixes <http://bugs.gnu.org/23605>.

* gnu/services/base.scm (urandom-seed-service): New procedure.
(%random-seed-file, urandom-seed-service-type): New variables.
(%urandom-seed-shepherd-service): New procedure.
(%base-services): Call 'urandom-seed-service'.
* doc/guix.texi (Base Services): Document it.
2016-05-28 19:59:31 -04:00
Efraim Flashner 76192896e9
services: Add connman-service.
* gnu/services/networking.scm (connman-service): New procedure.
(connman-service-type, %connman-activation): New variables.
(connman-shepherd-service): New procedure.
* doc/guix.texi (Networking Services): Document it.
2016-05-05 23:07:09 +03:00
Ludovic Courtès 958dd3ce68
utils: Move combinators to (guix combinators).
* guix/utils.scm (compile-time-value, memoize, fold2)
(fold-tree, fold-tree-leaves): Move to...
* guix/combinators: ... here.  New file.
* tests/utils.scm ("fold2, 1 list", "fold2, 2 lists")
(fold-tree tests): Move to...
* tests/combinators.scm: ... here.  New file.
* Makefile.am (MODULES, SCM_TESTS): Add them.
* gnu/packages.scm, gnu/packages/bootstrap.scm,
gnu/services/herd.scm, guix/build-system/gnu.scm,
guix/build-system/python.scm, guix/derivations.scm,
guix/gnu-maintenance.scm, guix/import/elpa.scm,
guix/scripts/archive.scm, guix/scripts/build.scm,
guix/scripts/graph.scm, guix/scripts/lint.scm,
guix/scripts/size.scm, guix/scripts/substitute.scm,
guix/serialization.scm, guix/store.scm, guix/ui.scm: Adjust imports
accordingly.
2016-05-04 23:35:55 +02:00
Ludovic Courtès 8bf92e3904
services: herd: Move UI handling to 'guix system'.
This makes (gnu services herd) independent of (guix ui).

* gnu/services/herd.scm (&shepherd-error, &service-not-found-error)
(&action-not-found-error, &action-exception-error)
(&unknown-shepherd-error): New error condition types.
(report-action-error): Remove.
(raise-shepherd-error): New procedure.
(display-message): Do not use 'info' and '_'.
(invoke-action): Use 'raise-shepherd-error' instead of
'report-action-error'.  Do not use 'warning'.
(current-services): Do not use 'warning'.
* guix/scripts/system.scm (with-shepherd-error-handling): New macro.
(report-shepherd-error, call-with-service-upgrade-info): New
procedures.
(upgrade-shepherd-services): Use it.
2016-05-04 23:35:55 +02:00
Ludovic Courtès 1ea507bce2 services: Move 'device-mapping-service' to (gnu system mapped-devices).
* gnu/services/base.scm (device-mapping-service-type)
(device-mapping-service): Move to...
* gnu/system/mapped-devices.scm (device-mapping-service-type):
(device-mapping-service): ... here.  New variables.
2016-04-18 01:24:06 +02:00
Ludovic Courtès 060d62a740 system: Add (gnu system mapped-devices).
* gnu/system/file-systems.scm (<mapped-device>, <mapped-device-type>):
Move to...
* gnu/system/mapped-devices.scm: ... here.  New file.
* gnu/system.scm, gnu/services/base.scm,
gnu/system/linux-initrd.scm: Use it.
* gnu-system.am (GNU_SYSTEM_MODULES): Add it.
* gnu.scm (%public-modules): Add it.
2016-04-18 01:24:06 +02:00
Alex Kost b3d05f4870 services: 'console-keymap-service' takes multiple files.
* gnu/services/base.scm (console-keymap-service-type): Type procedure
takes a list of files instead of a single file.
(console-keymap-service): Take 'files' as rest arguments.
* doc/guix.texi (Base Services): Improve documentation of
'console-keymap-service'.
2016-04-17 10:33:08 +03:00
Ludovic Courtès cc7234aede services: nscd: Make respawnable.
* gnu/services/base.scm (nscd-shepherd-service): Remove 'respawn?' field.
2016-03-24 22:47:15 +01:00
Ludovic Courtès f2ab925028 services: xorg: Fix ~/.xsession handling.
Fixes a regression introduced in c510cbb4ec.

* gnu/services/xorg.scm (xinitrc)[builder]: Add missing 'apply' when
XSESSION-FILE exists.
2016-03-24 11:01:07 +01:00
Ludovic Courtès 9b1cee97a5 services: postgresql: Use syslog.
Fixes <http://bugs.gnu.org/23064>.
Reported by Danny Milosavljevic <dannym@scratchpost.org>.

* gnu/services/databases.scm (%default-postgres-config): Add
'log_destination' line.
(postgresql-shepherd-service): Add requirement on 'syslogd'.
2016-03-23 00:23:12 +01:00
Ludovic Courtès cd6cc144e0 Merge branch 'security-updates' 2016-03-22 00:14:03 +01:00
Ludovic Courtès c510cbb4ec services: xorg: Accept session commands with arguments.
Before that, a session command with several items, such as
'gnome-session --disable-acceleration-check', would trigger the fallback
session.

* gnu/services/xorg.scm (xinitrc)[builder]: Accept command lines with
more than one arguments.
2016-03-18 19:42:00 +01:00
Andy Wingo 7a2413e46d gnu: services: Add GNOME and XFCE desktop services.
* gnu/services/desktop.scm (package-direct-input-selector): New
  function.
  (<gnome-desktop-configuration>, gnome-desktop-service-type)
  (<xfce-desktop-configuration>, xfce-desktop-service-type): New
  variables.
  (gnome-desktop-service, xfce-desktop-service): New public variables.

* doc/guix.texi (Desktop Services): Document new variables.
2016-03-15 21:03:27 +01:00
Ludovic Courtès f5a9103991 gnu: dbus: Incorporate "dbus-helper-search-path.patch".
* gnu/packages/glib.scm (dbus)[source]: Apply
"dbus-helper-search-path.patch".
(dbus/activation): Remove.
* gnu/services/dbus.scm (<dbus-configuration>)[dbus]: Default to DBUS.
(dbus-service): Likewise.
2016-03-09 15:31:23 +01:00
Ludovic Courtès 255f730879 gnu: eudev: Add dependency on blkid.
* gnu/packages/linux.scm (eudev)[inputs]: Add UTIL-LINUX.
(eudev-with-blkid): Remove.
* gnu/services/base.scm (udev-service): Use EUDEV instead of
EUDEV-WITH-BLKID.
* gnu/system.scm (%base-packages): Likewise.
2016-03-09 15:26:09 +01:00
Ludovic Courtès 956ad60cad services: elogind: Rely on D-Bus activation.
Previously elogind was explicitly spawned by the Shepherd.  Now it is
activated by dbus-daemon on demand.

* gnu/packages/freedesktop.scm (elogind)[arguments]: Add
'fix-service-file' phase.
* gnu/services/desktop.scm (elogind-shepherd-service): Remove.
(elogind-dbus-service): New procedure.
(elogind-service-type): Do not extend SHEPHERD-ROOT-SERVICE-TYPE.  Use
'elogind-dbus-service' for DBUS-ROOT-SERVICE-TYPE.
2016-03-07 00:01:03 +01:00
Ludovic Courtès 44abcb2868 doc: Mention syslogd configuration.
* gnu/services/base.scm (syslog-service): Add xref to Inetutils in the
docstring.
(%default-syslog.conf): Export.
* doc/guix.texi (Base Services): Update accordingly.
2016-03-04 11:48:52 +01:00
Andy Wingo 79fd74facd gnu: services: Start X with -configdir.
* gnu/services/xorg.scm (%default-xorg-modules): New public variable.
(xorg-configuration-directory): New function.
(xorg-start-command): Add #:modules keyword argument, defaulting to
%default-xorg-modules.  Build an xorg.conf.d directory from those
modules, and pass it to X via the -configdir parameter.
2016-02-24 11:49:57 -05:00
Andy Wingo ea84bd88da gnu: services: Install policies for polkit service.
* gnu/services/desktop.scm (polkit-etc-files): Add the polkit package
  itself to the list of packages to scan for .policy files.  This add
  support for pkexec.
2016-02-24 10:16:54 +01:00
Ludovic Courtès f2d8faff04 services: herd: Add missing newlines in error messages.
* gnu/services/herd.scm (report-action-error): Add missing newlines in
messages.
2016-02-23 13:03:23 +01:00
Leo Famulari 8823ed4e12 gnu: Fix syntax error in postgresql-service.
Fixes <http://bugs.gnu.org/22618>.
Reported by Danny Milosavljevic <dannym@scratchpost.org>.

* gnu/services/databases.scm (%default-postgres-config): Add missing
quote in default configuration.
2016-02-10 15:34:11 -05:00
Ludovic Courtès 6eb439070a file-systems: Spawn a Bournish REPL upon fsck failure.
Fixes <http://bugs.gnu.org/22588>.
Reported by Mark H Weaver <mhw@netris.org>.

* gnu/build/file-systems.scm (check-file-system): Pass
%BOURNISH-LANGUAGE as the argument to 'start-repl'.
* gnu/services.scm (activation-script): Add (guix build bournish).
* gnu/services/base.scm (file-system-shepherd-service)[imported-modules]:
Likewise.
* gnu/system/linux-container.scm (container-script): Likewise.
* gnu/system/vm.scm (expression->derivation-in-linux-vm): Likewise.
2016-02-08 23:46:46 +01:00
Ludovic Courtès e7ad0d5862 services: elogind: Extend PAM to use 'pam_elogind.so'.
Thanks to Andy Wingo <wingo@igalia.com> for explaining this at
<https://lists.gnu.org/archive/html/guix-devel/2015-08/msg00439.html>.

* gnu/services/desktop.scm (pam-extension-procedure): New procedure.
(elogind-service-type): Extend PAM-ROOT-SERVICE-TYPE.
2016-02-06 12:01:42 +01:00
Ludovic Courtès 05c5b16585 services: elogind: Add elogind to the global profile.
* gnu/services/desktop.scm (elogind-service-type): Extend
PROFILE-SERVICE-TYPE.
2016-02-05 22:10:42 +01:00
Ludovic Courtès edc891fa76 services: upower: Add upower to the global profile.
* gnu/services/desktop.scm (upower-service-type): Extend
PROFILE-SERVICE-TYPE.
2016-02-05 22:10:42 +01:00
Ludovic Courtès 234ea8a71c service: shepherd: All of the config file is in 'call-with-error-handling'.
* gnu/services/shepherd.scm (shepherd-configuration-file)[config]: Wrap
all the body in 'call-with-error-handling'.
2016-02-05 14:01:46 +01:00
Ludovic Courtès 081bd3bd29 service: shepherd: Guard against exceptions raised by 'start'.
Fixes <http://bugs.gnu.org/22548>.
Reported by Albin <albin@fripost.org>, Mark H Weaver, and Alex Kost.

* gnu/services/shepherd.scm (shepherd-configuration-file)[config]: Guard
against 'service-error?'.
2016-02-05 14:01:46 +01:00
Ludovic Courtès 1d6b7d5847 guix system: Simply warn if we cannot talk to the shepherd.
Before that 'open-connection' would return #f, and thus
'current-services' would return a single #f value when its continuation
expects two.

Reported by calher on #guix.

* gnu/services/herd.scm (open-connection): Rethrow system-error
exceptions.
(with-shepherd): Expect CONNECTION to always be true; remove useless
'dynamic-wind'.
* guix/scripts/system.scm (warn-on-system-error): New macro.
(upgrade-shepherd-services): Wrap body in 'warn-on-system-error'.
2016-02-05 14:01:46 +01:00
Ludovic Courtès 240b57f0ca guix system: 'reconfigure' loads and starts new services.
Partly fixes <http://bugs.gnu.org/22039>.

* gnu/services/herd.scm: New file.
* gnu-system.am (GNU_SYSTEM_MODULES): Add it.
* gnu/services/shepherd.scm (shepherd-service-canonical-name): New
procedure.
(shepherd-service-file): Export.
* guix/scripts/system.scm (upgrade-shepherd-services): New procedure.
(switch-to-system): Use it.
* guix/ui.scm (info): New procedure.
* doc/guix.texi (Invoking guix system): Mention system services.
2016-02-03 22:28:28 +01:00
Ludovic Courtès 400ed6acdd gnu: eudev: Add variant that depends on libblkid.
This fixes a bug whereby /dev/disk/by-{label,id} would be missing on
GuixSD (/dev/disk/by-id would still contain device-mapped partitions
though.)

Reported by Mark H Weaver <mhw@netris.org>.

* gnu/packages/linux.scm (eudev-with-blkid): New variable.
* gnu/services/base.scm (udev-service): #:udev defaults to
EUDEV-WITH-BLKID.
* gnu/system.scm (%base-packages): Replace EUDEV with EUDEV-WITH-BLKID.
2016-02-02 21:16:59 +01:00
Alex Kost d4053c710b services: Rename 'dmd' services to 'shepherd'.
* gnu/services/shepherd.scm (dmd-root-service-type, %dmd-root-service)
  (dmd-service-type, <dmd-service>, dmd-service, dmd-service?)
  (make-dmd-service, dmd-service-documentation, dmd-service-provision)
  (dmd-service-requirement, dmd-service-respawn, dmd-service-start)
  (dmd-service-stop, dmd-service-auto-start?, dmd-service-modules)
  (dmd-service-imported-modules, dmd-service-file-name, dmd-service-file)
  (dmd-service-back-edges): Rename to...
  (shepherd-root-service-type, %shepherd-root-service, shepherd-service-type)
  (<shepherd-service>, shepherd-service, shepherd-service?)
  (make-shepherd-service, shepherd-service-documentation)
  (shepherd-service-provision, shepherd-service-requirement)
  (shepherd-service-respawn, shepherd-service-start)
  (shepherd-service-stop, shepherd-service-auto-start?)
  (shepherd-service-modules, shepherd-service-imported-modules)
  (shepherd-service-file-name, shepherd-service-file)
  (shepherd-service-back-edges): ...this
* gnu/services.scm: Adjust comments.
* gnu/services/avahi.scm (avahi-dmd-service): Rename to...
  (avahi-shepherd-service): ... this.
* gnu/services/base.scm (%root-file-system-dmd-service)
  (file-system->dmd-service-name, mapped-device->dmd-service-name)
  (dependency->dmd-service-name, file-system-dmd-service)
  (mingetty-dmd-service, nscd-dmd-service, guix-dmd-service)
  (guix-publish-dmd-service, udev-dmd-service, gpm-dmd-service): Rename to...
  (%root-file-system-shepherd-service)
  (file-system->shepherd-service-name, mapped-device->shepherd-service-name)
  (dependency->shepherd-service-name, file-system-shepherd-service)
  (mingetty-shepherd-service, nscd-shepherd-service, guix-shepherd-service)
  (guix-publish-shepherd-service, udev-shepherd-service)
  (gpm-shepherd-service): ... this.
* gnu/services/databases.scm (postgresql-dmd-service): Rename to...
  (postgresql-shepherd-service): ... this.
* gnu/services/desktop.scm (upower-dmd-service, elogind-dmd-service):
  Rename to...
  (upower-shepherd-service, elogind-shepherd-service): ... this.
* gnu/services/dbus.scm (dbus-dmd-service): Rename to...
  (dbus-shepherd-service): ... this.
* gnu/services/lirc.scm (lirc-dmd-service): Rename to...
  (lirc-shepherd-service): ... this.
* gnu/services/mail.scm (dovecot-dmd-service): Rename to...
  (dovecot-shepherd-service): ... this.
* gnu/services/networking.scm (ntp-dmd-service, tor-dmd-service)
  (bitlbee-dmd-service, wicd-dmd-service, network-manager-dmd-service): Rename to...
  (dbus-shepherd-service): ... this.
* gnu/services/ssh.scm (lsh-dmd-service): Rename to...
  (lsh-shepherd-service): ... this.
* gnu/services/web.scm (nginx-dmd-service): Rename to...
  (nginx-shepherd-service): ... this.
* gnu/services/xorg.scm (slim-dmd-service): Rename to...
  (slim-shepherd-service): ... this.
* gnu/system.scm (essential-services): Use '%shepherd-root-service'.
* gnu/system/install.scm (cow-store-service-type): Adjust accordingly.
* guix/scripts/system.scm (dmd-service-node-label, dmd-service-node-type)
  (export-dmd-graph): Likewise.
* tests/guix-system.sh: Likewise.
* tests/services.scm ("dmd-service-back-edges"): Rename to...
  ("shepherd-service-back-edges"): Adjust accordingly.
* doc/guix.texi: Likewise.
* doc/images/service-graph.dot: Use 'shepherd' service name.
2016-01-29 20:21:53 +03:00
Alex Kost 26b94866ad services: xorg: Use 'shepherd' instead of 'dmd'.
* gnu/services/xorg.scm (slim-configuration-dmd): Rename to...
  (slim-configuration-shepherd): ... this.
  (slim-shepherd-service): Adjust accordingly.
  (slim-service): Take 'shepherd' keyword argument.
2016-01-29 20:21:53 +03:00
Alex Kost fe1ad5f5db services: shepherd: Rename shepherd configuration file.
* gnu/services/shepherd.scm (dmd-configuration-file): Rename to...
  (shepherd-configuration-file): ... this.  Use "shepherd.conf" name.
  (dmd-boot-gexp): Use it.
2016-01-29 20:21:53 +03:00
Alex Kost 0190c1c02f Rename (gnu services dmd) to (gnu services shepherd).
* gnu/services/dmd.scm: Rename to...
* gnu/services/shepherd.scm: ... this.
* gnu/system.scm: Use it.
* gnu/system/install.scm: Likewise.
* gnu/services/xorg.scm: Likewise.
* gnu/services/web.scm: Likewise.
* gnu/services/ssh.scm: Likewise.
* gnu/services/networking.scm: Likewise.
* gnu/services/mail.scm: Likewise.
* gnu/services/lirc.scm: Likewise.
* gnu/services/desktop.scm: Likewise.
* gnu/services/dbus.scm: Likewise.
* gnu/services/databases.scm: Likewise.
* gnu/services/base.scm: Likewise.
* gnu/services/avahi.scm: Likewise.
* guix/scripts/system.scm: Likewise.
* tests/services.scm: Likewise.
* tests/guix-system.sh: Likewise.
* doc/guix.texi (Shepherd Services): Adjust accordingly.
* gnu-system.am (GNU_SYSTEM_MODULES): Likewise.
* po/guix/POTFILES.in: Likewise.
2016-01-29 20:21:53 +03:00
Alex Kost b8c02c18b4 Rename '/root/etc/dmd' directory and 'do-not-kill' file.
* gnu/services/base.scm (%do-not-kill-file): Rename to
  "/etc/shepherd/do-not-kill".
* gnu/build/linux-boot.scm (mount-root-file-system): Rename
  "/root/etc/dmd" to "/root/etc/shepherd".
2016-01-29 20:20:19 +03:00
Alex Kost 34044d551f Use 'shepherd' instead of 'dmd' as init system.
* gnu/services/dmd.scm (dmd-boot-gexp): Use binary from 'shepherd' package.
  (dmd-root-service-type): Use 'shepherd' package.
  (%default-modules): Use (shepherd service) module.
* gnu/services/base.scm (%root-file-system-dmd-service): Use
  'stop-logging' procedure to close shepherd log.
2016-01-29 12:07:32 +03:00
Ludovic Courtès 9a8b9eb8de services: guix: Provide Guix via 'profile-service-type'.
* gnu/services/base.scm (guix-service-type): Extend
PROFILE-SERVICE-TYPE.
* gnu/system.scm (%base-packages): Remove GUIX.
2016-01-27 15:48:35 +01:00
Ludovic Courtès c273d81bfa services: dmd: Provide dmd via 'profile-service-type'.
* gnu/services/dmd.scm (dmd-root-service-type): Extend
PROFILE-SERVICE-TYPE.
* gnu/system.scm (%base-packages): Remove dmd.
2016-01-27 15:48:35 +01:00
Ludovic Courtès 893106cbbf services: avahi: Export service type.
* gnu/services/avahi.scm: Export 'avahi-service-type'.
2016-01-21 00:22:34 +01:00
Ludovic Courtès be21979d85 file-systems: Add a 'mount?' field.
Fixes <http://bugs.gnu.org/22176>.
Reported by Florian Paul Schmidt <mista.tapas@gmx.net>.

* gnu/system/file-systems.scm (<file-system>)[mount?]: New field.
(file-system->spec): Adjust accordingly.
* gnu/services/base.scm (file-system-dmd-service): Return the empty list
when FILE-SYSTEM has 'mount?' set to false.
(user-processes-service): Select the subset of FILE-SYSTEMS that matches
'file-system-mount?'.
* doc/guix.texi (File Systems): Document it.
2015-12-22 00:29:21 +01:00
Ludovic Courtès e43e84ba7a services: Add 'fstab-service-type'.
* gnu/services/base.scm (file-system->fstab-entry)
(file-systems->fstab): New procedures.
(fstab-service-type): New variable.
* gnu/services/base.scm (file-system-dmd-service): New procedure, taken
from...
(file-system-service-type): ... here.
* gnu/system.scm (essential-services): Add FSTAB-SERVICE-TYPE instance.
2015-12-22 00:04:36 +01:00
Andy Wingo d8c18af834 gnu: Add dovecot service
* gnu/services/mail.scm: New file.
(&dovecot-configuration-error, dovecot-configuration-error?)
(dovecot-service, dovecot-configuration, dict-configuration)
(passdb-configuration, userdb-configuration)
(unix-listener-configuration, fifo-listener-configuration)
(inet-listener-configuration, service-configuration)
(protocol-configuration, plugin-configuration, mailbox-configuration)
(namespace-configuration, opaque-dovecot-configuration): New public
variables.

* gnu-system.am (GNU_SYSTEM_MODULES): Add (gnu services mail).

* doc/guix.texi (Mail Services): New node.
2015-12-18 09:24:27 +01:00
宋文武 e10964efd2 services: Add 'session-environment-service'.
* gnu/services/base.scm (session-environment-service): New procedure.
(session-environment-service-type): New variable.
(environment-variables->environment-file): New procedure.
2015-12-05 10:51:49 +08:00
Ricardo Wurmus eac26c3b09 services: Add pkexec to setuid programs.
* gnu/services/desktop.scm (polkit-setuid-programs): Add pkexec to
  list of setuid programs.
2015-11-29 20:33:35 +01:00
Ludovic Courtès 6629099a63 services: tor: Store private data under /var/lib/tor.
* gnu/services/networking.scm (tor-configuration->torrc): Add
'DataDirectory' clause.  Change 'HiddenServiceDir' to
/var/lib/tor/hidden-services/NAME.
(tor-hidden-service-activation): Create /var/lib/tor.
(tor-hidden-service): Adjust docstring.
* doc/guix.texi (Networking Services): Adjust accordingly.
2015-11-27 23:29:51 +01:00
Ludovic Courtès 5ee35eb747 services: tor: Write to syslog.
* gnu/services/networking.scm (tor-configuration->torrc): Add "Log
notice syslog".
(tor-dmd-service): Add 'syslogd' to 'requirement'.
2015-11-27 23:08:00 +01:00
Ludovic Courtès 6331bde73f services: Add 'tor-hidden-service'.
* gnu/services/networking.scm (<tor-configuration>, <hidden-service>):
New record types.
(tor-configuration->torrc): New procedure.
(tor-dmd-service): Use it.
(tor-hidden-service-activation): New procedure.
(tor-service-type)[extensions]: Extend ACTIVATION-SERVICE-TYPE.
[compose, extend]: New fields.
(tor-service): Use 'tor-configuration'.
(tor-hidden-service-type): New variable.
(tor-hidden-service): New procedure.
2015-11-27 23:04:49 +01:00
Ludovic Courtès fde40c98f9 services: lsh: Correctly handle #:interfaces option.
* gnu/services/ssh.scm (lsh-dmd-service)[lsh-command]: Pass a series of
--interface flags instead of the nonexistent --interfaces option.
2015-11-27 22:46:27 +01:00
宋文武 7234ad4f54 services: Add network-manager-service.
* gnu/services/networking.scm (network-manager-service): New procedure.
(network-manager-service-type, %network-manager-activation): New variables.
(network-manager-dmd-service): New procedure.
2015-11-26 13:50:13 +08:00
David Thompson 4b7513e043 services: xorg: Export additional symbols.
'slim-configuration' and 'slim-service-type' are needed if one wishes to
use 'modify-services' on a service list that includes the slim service.

* gnu/services/xorg.scm: Export 'slim-configuration' and
  'slim-service-type'.
2015-11-25 12:47:58 -05:00
Ludovic Courtès b9c7ed71b1 services: dmd: Spawn a REPL upon failure to load a service definition.
Fixes <http://bugs.gnu.org/19779>.
Reported by Mark H Weaver <mhw@netris.org>.

* gnu/services/dmd.scm (dmd-configuration-file)[config]: Wrap
'primitive-load' calls in 'call-with-error-handling'.
2015-11-25 11:59:54 +01:00
Ludovic Courtès 479b417b54 services: dmd: Strip the default list of modules.
* gnu/services/dmd.scm (%default-imported-modules): Remove (gnu build
file-systems).
(%default-modules): Likewise, and remove (ice-9 ftw).
* gnu/services/base.scm (file-system-service-type): Add 'modules' and
'imported-modules' fields.
2015-11-25 11:59:54 +01:00
Ludovic Courtès fae685b9cc services: dmd: Add 'modules' and 'imported-modules' fields.
* gnu/services/dmd.scm (%default-imported-modules, %default-modules):
New variables.
* gnu/services/dmd.scm (<dmd-service>)[modules, imported-modules]: New
field.
* gnu/services/dmd.scm (dmd-service-file-name, dmd-service-file): New
procedures.
(dmd-configuration-file)[modules]: Compute based on the
'imported-modules' field of SERVICES.
(dmd-configuration-file): Remove 'use-modules' form.  Use
'dmd-service-file', and call 'primitive-load' on each file.
* doc/guix.texi (dmd Services): Document the new fields.
2015-11-25 11:59:54 +01:00
Ludovic Courtès 2d2651e781 services: dmd: Error out upon unmet dmd requirements.
* gnu/services/dmd.scm (assert-no-duplicates): Rename to...
(assert-valid-graph): ... this.
[provisions]: New variable.
[assert-satisfied-requirements]: New procedure.
Use it.
* tests/guix-system.sh: Add test with unmet dmd requirements.
2015-11-24 23:54:30 +01:00
David Thompson a907d9973a gnu: services: Fix typo in gpm-dmd-service.
* gnu/services/base.scm (gpm-dmd-service): s/dmd/gpm/
2015-11-20 09:56:41 -05:00
Ricardo Wurmus 80e6f37e30 services: Add udev-rule procedure.
* gnu/services/base.scm (udev-rule): New procedure.
(kvm-udev-rule): Rewrite as variable in terms of udev-rule.
2015-11-19 16:10:52 +01:00
Ricardo Wurmus c797fabe79 services: Export udev-configuration procedures.
* gnu/services/base.scm (udev-configuration, udev-configuration?,
  udev-configuration-rules): Export.
2015-11-18 22:04:48 +01:00
Ludovic Courtès 8664cc882c services: Add 'gpm-service'.
* gnu/services/base.scm (<gpm-configuration>): New record type.
  (gpm-dmd-service): New procedure.
  (gpm-service-type): New variable.
  (gpm-service): New procedure.
* doc/guix.texi (Base Services): Document it.
2015-11-07 18:56:17 +01:00
Ludovic Courtès 6e82863463 system: Rename (gnu system linux) to (gnu system pam).
* gnu/system/linux.scm: Rename to...
* gnu/system/pam.scm: ... this.
* gnu-system.am (GNU_SYSTEM_MODULES): Adjust accordingly.
* gnu.scm, gnu/services/base.scm, gnu/services/desktop.scm,
  gnu/services/networking.scm, gnu/services/ssh.scm,
  gnu/services/xorg.scm, gnu/system.scm, gnu/system/vm.scm: Likewise.
2015-11-03 18:11:45 +01:00
Ludovic Courtès 1c52181f33 services: Add 'guix-publish-service'.
* gnu/services/base.scm (<guix-publish-configuration>): New record
  type.
  (guix-publish-dmd-service): New procedure.
  (%guix-publish-accounts, guix-publish-service-type): New variables.
  (guix-publish-service): New procedure.
* doc/guix.texi (Invoking guix publish): Add xref to
  'guix-publish-service' anchor.
  (Base Services): Document 'guix-publish-service'.
2015-11-03 18:11:45 +01:00
Ludovic Courtès beca0807eb services: udisks: Add UDisks to the system profile.
* gnu/services/desktop.scm (udisks-service-type): Extend
  PROFILE-SERVICE-TYPE.
2015-11-02 22:25:12 +01:00
Ludovic Courtès 1065bed9c4 services: avahi: Add Avahi to the system profile.
* gnu/services/avahi.scm (avahi-service-type): Extend
  PROFILE-SERVICE-TYPE.
  (avahi-service): Adjust docstring.
* doc/guix.texi (Networking Services): Adjust accordingly.
* gnu/system/examples/desktop.tmpl (packages): Remove AVAHI.
2015-11-02 22:25:12 +01:00
Ludovic Courtès e9b8212414 services: slim: Add xterm to the system profile.
* gnu/services/xorg.scm (slim-service-type): Extend
  PROFILE-SERVICE-TYPE.
* gnu/system/examples/desktop.tmpl (packages): Remove XTERM.
2015-11-02 22:25:12 +01:00
Ludovic Courtès 87f4001146 services: wicd: Add Wicd to the system profile.
* gnu/services/networking.scm (wicd-service-type): Extend
  PROFILE-SERVICE-TYPE.
  (wicd-service): Mention it in docstring.
* doc/guix.texi (Networking Services): Update documentation
  accordingly.
* gnu/system/examples/desktop.tmpl (packages): Remove WICD.
2015-11-02 22:25:12 +01:00
Ludovic Courtès 7824d4450d Revert "services: polkit: Use the right executable name for PAM."
This reverts commit 7f39e181df.

Polkit actually uses the name "polkit-1" in calls to 'pam_start'.
2015-11-01 22:24:19 +01:00
Ludovic Courtès 2b9e0a948b services: Add 'udisks-service'.
* gnu/services/desktop.scm (<udisks-configuration>): New record type.
  (udisks-service-type): New variable.
  (udisks-service): New procedure.
  (%desktop-services): Use it.
* doc/guix.texi (Desktop Services): Document it.
2015-11-01 17:56:48 +01:00
Ludovic Courtès 222e3319bd services: 'polkit-service-type' can now be extended.
* gnu/packages/polkit.scm (polkit)[source]: Adjust snippet so that rules
  and actions are looked for under /etc/polkit-1.
* gnu/services/desktop.scm (<polkit-configuration>): New record type.
  (polkit-directory, polkit-etc-files, polkit-setuid-programs): New
  procedures.
  (polkit-service-type)[compose, extend]: New fields.
  (polkit-service): Refine docstring.
  (colord-service-type): Extend POLKIT-SERVICE-TYPE.
  (elogind-configuration-file): Extend POLKIT-SERVICE-TYPE.
* doc/guix.texi (Desktop Services): Update 'polkit-service'
  documentation.
2015-11-01 17:56:47 +01:00
Ludovic Courtès d9b9454c98 Merge branch 'dbus-update' 2015-10-31 15:11:58 +01:00
Ludovic Courtès 375c610844 services: 'tor-service' takes a 'config-file' parameter.
* gnu/services/networking.scm (tor-dmd-service): Take a 'config'
  parameter and honor it.
  (tor-service): Take a 'config-file' parameter.  Pass it in the
  service's value.
* doc/guix.texi (Networking Services): Adjust accordingly.
2015-10-31 15:11:48 +01:00
宋文武 eed588d997 Merge branch 'master' into dbus-update 2015-10-30 20:50:26 +08:00
Ludovic Courtès 6726282b20 services: Add screen-locker service.
* gnu/system/linux.scm (base-pam-services): Remove "xlock" and
  "xscreensaver".
* gnu/services/xorg.scm (<screen-locker>): New record type.
  (screen-locker-pam-services, screen-locker-setuid-programs,
  screen-locker-service): New procedures.
  (screen-locker-service-type): New variable.
* gnu/services/desktop.scm (%desktop-services): Use them.
* doc/guix.texi (X Window): Document 'screen-locker-service'.
  (Desktop Services): Mention it.
2015-10-29 19:07:58 +01:00
Ludovic Courtès e502bf8953 system: File systems depend on their corresponding device mappings.
Fixes a regression introduced in commit 0adfe95.

* gnu/system.scm (other-file-system-services)[requirements]: Remove.
  [add-dependencies]: New procedure.
  Use it.
* gnu/system/file-systems.scm (<file-system>)[dependencies]: Update
  comment.
* gnu/services/base.scm (mapped-device->dmd-service-name,
  dependency->dmd-service-name): New procedures.
  (file-system-service-type): Use it.
2015-10-29 19:07:58 +01:00
Ludovic Courtès cd6f6c22fb services: Add 'modify-services'.
* gnu/services.scm (%modify-service, modify-services): New macros.
* gnu/services/base.scm (mingetty-service-type, guix-service-type):
  Export.
* emacs/guix-devel.el (guix-devel-keywords): Add 'modify-services'.
  Ditto in 'guix-devel-scheme-indent' call.
* doc/guix.texi (Using the Configuration System): Give an example of
  'modify-services'.
  (Service Reference): Document it.
2015-10-28 21:58:25 +01:00
Ludovic Courtès b0b9f6e0a6 services: 'guix-configuration' has a 'substitute-urls' field.
* gnu/services/base.scm (<guix-configuration>)[substitute-urls]: New
  field.
  (guix-dmd-service): Honor it.
* doc/guix.texi (Base Services): Document it.
2015-10-28 21:58:25 +01:00
Mark H Weaver d3365d4866 Merge branch 'master' into dbus-update 2015-10-23 23:11:38 -04:00
Ludovic Courtès 26909789d0 services: Rely on D-Bus activation for colord, geoclue, and polkit.
* gnu/services/desktop.scm (colord-dmd-service): Remove.
  (colord-service-type): Adjust accordingly.
  (geoclue-dmd-service): Remove.
  (geoclue-service-type): Adjust accordingly.
  (polkit-dmd-service): Remove.
  (polkit-service-type): Adjust accordingly.
2015-10-22 00:44:18 +02:00
Ludovic Courtès cde0402169 services: dbus: Support service activation.
* gnu/services/dbus.scm (system-service-directory): New procedure.
  (dbus-configuration-directory)[services->sxml]: Add
  /etc/dbus-1/system-services <servicedir> tag, and remove the
  per-service "/share/dbus-1/system-services" tag.
  Symlink OUTPUT/system-services.
  (dbus-setuid-programs): New procedure.
  (dbus-root-service-type): Extend SETUID-PROGRAM-SERVICE-TYPE.
  (dbus-service): Default to DBUS/ACTIVATION.
2015-10-22 00:41:09 +02:00
Ludovic Courtès 4a663ca4e8 services: dbus: Honor the config's dbus package.
* gnu/services/dbus.scm (dbus-dmd-service): Rewrite using 'match-lambda'
  so that the config's dbus package is used.  Fixes a regression
  introduced in 64643b9.
2015-10-21 23:37:02 +02:00
Eric Bavier d1ccd094f9 services: xorg: Include font-alias in default FontPath.
* gnu/services/xorg.scm (xorg-configuration-file): Add font-alias directories
  to xserver.conf FontPath.
2015-10-20 15:40:09 -05:00
宋文武 64643b90ab services: dbus: Build '/etc/dbus-1/system-local.conf'.
* gnu/services/dbus.scm (dbus-etc-files): New procedure.
  (dbus-dmd-service): Remove the use of '--config-file'.
  (dbus-configuration-directory): Adjust accordingly.
  (dbus-root-service-type): Add extension of ETC-SERVICE-TYPE.
2015-10-19 19:25:15 +08:00
Ludovic Courtès 5f44ee4fa0 services: Unmount user file systems after process termination.
* gnu/services/base.scm (user-unmount-service-type): Change label and
  dmd name to 'user-file-systems'.
  (user-processes-service-type)[requirement]: Add 'user-file-systems'.
2015-10-14 21:39:06 +02:00
Ludovic Courtès 80a6773483 services: Add 'dmd-service-back-edges'.
* gnu/services/dmd.scm (dmd-service-back-edges): New procedure.
* tests/services.scm ("dmd-service-back-edges"): New test.
2015-10-14 21:39:06 +02:00
Ludovic Courtès c5d735f798 services: Prefix <dmd-service> accessors with 'dmd-'.
* gnu/services/dmd.scm (<dmd-service>): Prefix accessor identifiers with
  'dmd-', as was intended.  Update users accordingly.
2015-10-14 21:39:06 +02:00
Ludovic Courtès 00184239c3 services: 'dmd-service-type' takes a service name.
* gnu/services/dmd.scm (dmd-service-type): Add 'service-name'
  parameter.
* gnu/services/base.scm, gnu/services/networking.scm,
  gnu/system/install.scm: Adjust callers.
2015-10-14 21:39:05 +02:00
Ludovic Courtès cc9c1f3935 doc: Update "Name Service Switch" to new service framework.
* gnu/services/avahi.scm (avahi-service): Mention the extension of
  nscd.
* doc/guix.texi (Networking Services): Update accordingly.
  (Name Service Switch): Remove '%my-base-services' example and
  explanation.
2015-10-13 00:06:11 +02:00
Ludovic Courtès 7f39e181df services: polkit: Use the right executable name for PAM.
* gnu/services/desktop.scm (%polkit-pam-services): Change "polkit-1" to
  "polkitd", which is the actual name of the executable.
2015-10-11 22:28:10 +02:00
Ludovic Courtès 2da4f2dd8e services: upower: Remove unused "upower" account.
* gnu/services/desktop.scm (%upower-accounts): Remove.
  (%upower-activation): Remove references to the "upower" account.
  (upower-service-type): Remove extension of ACCOUNT-SERVICE-TYPE.
2015-10-11 22:28:10 +02:00
Ludovic Courtès 0adfe95a3e services: Introduce extensible services.
This patch rewrites GuixSD services to make them extensible.

* gnu-system.am (GNU_SYSTEM_MODULES): Add gnu/services/dbus.scm.
* gnu/services.scm (<service>): Replace with new record type.
  (<service-extension>, <service-type>): New record types.
  (write-service-type, compute-boot-script, second-argument): New
  procedures.
  (%boot-service, boot-service-type): New variables.
  (file-union, directory-union, modprobe-wrapper,
  activation-service->script, activation-script,
  gexps->activation-gexp): New procedures.
  (activation-service-type, %activation-service): New variables.
  (etc-directory, files->etc-directory, etc-service): New procedures.
  (etc-service-type, setuid-program-service, firmware-service-type): New
  variables.
  (firmware->activation-gexp): New procedure.
  (&service-error, &missing-target-service-error,
  &ambiguous-target-service-error): New condition types.
  (service-back-edges, fold-services): New procedures.
* gnu/services/avahi.scm (<avahi-configuration>): New record type.
  (configuration-file): Replace keyword parameters with a single
  'config' parameter.
  (%avahi-accounts, %avahi-activation, avahi-service-type): New
  variables.
  (avahi-dmd-service): New procedure.
  (avahi-service): Rewrite using 'service' and 'avahi-configuration'.
* gnu/services/base.scm (%root-file-system-dmd-service,
  root-file-system-service-type): New variables.
  (root-file-system-service): Use them.
  (file-system->dmd-service-name): New procedure.
  (file-system-service-type): New variable.
  (file-system-service): Use it.  Replace keyword parameters with a
  single 'file-system' object.
  (user-unmount-service-type): New variable.
  (user-unmount-service): Use it.
  (user-processes-service-type): New variable.
  (user-processes-service): Use it.
  (host-name-service-type): New variable.
  (host-name-service): Use it.
  (console-keymap-service-type): New variable.
  (console-keymap-service): Use it.
  (console-font-service-type): New variable.
  (console-font-service): Use it.
  (mingetty-pam-service, mingetty-dmd-service): New procedures.
  (mingetty-service-type): New variable.
  (mingetty-service): Use it.
  (nscd-dmd-service): New procedure.
  (nscd-activation, nscd-service-type): New variables.
  (nscd-service): Use the latter.
  (syslog-service-type): New variable.
  (syslog-service): Use it.
  (<guix-configuration>): New record type.
  (%default-guix-configuration): New variable.
  (guix-dmd-service, guix-accounts, guix-activation): New procedures.
  (guix-service-type): New variable.
  (guix-service): Replace list of keyword parameters with a single
  'config' parameter.  Rewrite using 'service'.
  (<udev-configuration>): New record type.
  (udev-dmd-service): New procedure.
  (udev-service-type): New variable.
  (udev-service): Use it.
  (device-mapping-service-type): New variable.
  (device-mapping-service): Use it.
  (swap-service-type): New variable.
  (swap-service): Use it.
* gnu/services/databases.scm (<postgresql-configuration>): New record
  type.
  (%postgresql-accounts, postgresql-activation): New variables.
  (postgresql-dmd-service): New procedure.
  (postgresql-service): Rewrite using 'service' and
  'postgresql-configuration'.
* gnu/services/dbus.scm: New file.
* gnu/services/desktop.scm (dbus-configuration-directory, dbus-service):
  Remove.
  (wrapped-dbus-service): New procedure.
  (<upower-configuration>): New record type.
  (upower-configuration-file): Replace keyword parameters with single
  <upower-configuration> parameter.
  (%upower-accounts, %upower-activation): New variables.
  (upower-dbus-service, upower-dmd-service): New procedures.
  (upower-service-type): New variable.
  (upower-service): Rewrite using 'service' and 'upower-configuration'.
  (%colord-activation, %colord-accounts): New variables.
  (colord-dmd-service): New procedure.
  (colord-service-type): New variable.
  (colord-service): Rewrite using 'service'.
  (<geoclue-configuration>): New record type.
  (geoclue-configuration-file): Replace keyword parameters with a single
  'config' parameter.
  (geoclue-dbus-service, geoclue-dmd-service): New procedures.
  (%geoclue-accounts, geoclue-service-type): New variables.
  (geoclue-service): Rewrite using 'service' and
  'geoclue-configuration'.
  (%polkit-accounts, %polkit-pam-services, polkit-service-type): New
  variables.
  (polkit-dmd-service): New procedure.
  (polkit-service): Rewrite using 'service'.
  (<elogind-configuration>)[elogind]: New field.
  (elogind-dmd-service): New procedure.
  (elogind-service-type): New variable.
  (elogind-service): Rewrite using 'service'.
  (%desktop-services): Remove argument to 'dbus-service'.  Remove 'map'
  over %BASE-SERVICES.
* gnu/services/dmd.scm (dmd-boot-gexp): New procedure.
  (dmd-root-service-type, %dmd-root-service): New variables.
  (dmd-service-type): New macro.
  (<dmd-service>): New record type.
* gnu/services/lirc.scm (<lirc-configuration>): New record type.
  (%lirc-activation): New variable.
  (lirc-dmd-service): New procedure.
  (lirc-service-type): New variable.
  (lirc-service): Rewrite using 'service' and 'lirc-configuration'.
* gnu/services/networking.scm (<static-networking>): New record type.
  (static-networking-service-type): New variable.
  (static-networking-service): Rewrite using 'service' and
  'static-networking'.
  (dhcp-client-service-type): New variable.
  (dhcp-client-service): Rewrite using 'service'.
  (<ntp-configuration>): New record type.
  (ntp-dmd-service): New procedure.
  (ntp-service-type): New variable.
  (ntp-service): New procedure.
  (%tor-accounts, tor-service-type): New variable.
  (tor-dmd-service): New procedure.
  (tor-service): Rewrite using 'service'.
  (<bitlbee-configuration>): New record type.
  (bitlbee-dmd-service): New procedure.
  (%bitlbee-accounts, %bitlbee-activation, bitlbee-service-type): New
  variables.
  (bitlbee-service): Rewrite using 'service'.
  (%wicd-activation): New variable.
  (wicd-dmd-service): New procedure.
  (wicd-service-type): New variable.
  (wicd-service): Rewrite using 'service'.
* gnu/services/ssh.scm (<lsh-configuration>): New record type.
  (activation): Rename to...
  (lsh-initialization): ... this.
  (lsh-activation, lsh-dmd-service, lsh-pam-services): New procedures.
  (lsh-service-type): New variable.
  (lsh-service): Rewrite using 'service' and 'lsh-configuration'.
* gnu/services/web.scm (<nginx-configuration>): New record type.
  (%nginx-accounts): New variable.
  (nginx-activation, nginx-dmd-service): New procedures.
  (nginx-service-type): New variable.
  (nginx-service): Rewrite using 'service' and 'nginx-configuration'.
* gnu/services/xorg.scm (<slim-configuration>): New record type.
  (slim-pam-service, slim-dmd-service): New procedures.
  (slim-service-type): New variable.
  (slim-service): Rewrite using 'service' and 'slim-configuration'.
* gnu/system.scm (file-union): Remove.
  (other-file-system-services): Adjust to new 'file-system-service'
  signature.
  (essential-services): Add #:container? parameter.  Add
  %DMD-ROOT-SERVICE, %ACTIVATION-SERVICE, and calls to
  'pam-root-service', 'account-service', 'operating-system-etc-service',
  and a SETUID-PROGRAM-SERVICE instance.
  (operating-system-services): Pass #:container? to 'essential-services.
  (etc-directory): Remove.
  (operating-system-etc-service): New procedure.  Rewrite as a call to
  'etc-service'.
  (operating-system-accounts): Change to not return accounts required by
  services.
  (operating-system-etc-directory): Rewrite as a call to 'fold-services'
  and 'etc-directory'.
  (user-group->gexp, user-account->gexp, modprobe-wrapper): Remove.
  (operating-system-activation-script): Rewrite as a call to
  'fold-services' and 'activation-service->script'.
  (operating-system-boot-script): Likewise.
  (operating-system-derivation): Add call to 'lower-object'.
  (emacs-site-file, emacs-site-directory, shells-file): Change to use
  'computed-file' and 'scheme-file' instead of the monadic procedures.
* gnu/system/install.scm (cow-store-service-type): New variable.
  (cow-store-service): Rewrite using 'service'.
  (/etc/configuration-files): New procedure.
  (configuration-template-service-type,
  %configuration-template-service): New variables.
  (configuration-template-service): Remove.
  (installation-services): Adjust accordingly.  Adjust argument to
  'guix-service'.
* gnu/system/linux.scm (/etc-entry, pam-root-service): New procedures.
  (pam-root-service-type): New variable.
* gnu/system/shadow.scm (user-group->gexp, user-account->gexp,
  account-activation, etc-skel, account-service): New procedures.
  (account-service-type): New variable.
* tests/services.scm: New file.
* doc/guix.texi (Base Services, Desktop Services): Adjust accordingly.
  (Defining Services): Rewrite.
* doc/images/service-graph.dot: New file.
* doc.am (DOT_FILES): Add it.
* po/guix/POTFILES.in: Add gnu/services.scm.
2015-10-10 22:55:15 +02:00
Ludovic Courtès b893f1aec3 services: nscd-service: Fit everything into <nscd-configuration>.
* gnu/services/base.scm (<nscd-configuration>)[glibc, name-services]:
  New fields.
  (nscd-service): Remove #:glibc and #:name-services parameters.  Adjust
  body to take those from CONFIG.
* gnu/services/desktop.scm (%desktop-services): Adjust accordingly.
* doc/guix.texi (Base Services): Adjust accordingly.
  (Name Service Switch): Adjust example.
2015-10-10 22:46:14 +02:00
Ludovic Courtès 66e4f01c60 services: mingetty-service: Use <mingetty-configuration> objects.
* gnu/services/base.scm (<mingetty-configuration>): New record type.
  (mingetty-service): Expect a single <mingetty-configuration> instead
  of keyword arguments.
  (%base-services): Adjust accordingly.
* gnu/system/install.scm (installation-services): Likewise.
* doc/guix.texi (Base Services): Adjust accordingly.
2015-10-10 22:46:14 +02:00
Ludovic Courtès be1c2c54d9 system: Make service procedures non-monadic.
* gnu/services/avahi.scm (configuration-file): Use 'plain-file' instead
  of 'text-file'.
  (avahi-service): Turn into a regular procedure that returns a <service>.
* gnu/services/base.scm (root-file-system-service, file-system-service,
  user-unmount-service, user-processes-service, host-name-service,
  console-keymap-service, console-font-service, mingetty-service,
  nscd.conf-file, nscd-service): Likewise.
  (%default-syslog.conf): New variable.
  (syslog-service): Use it.  Turn into a regular procedure.
  (guix-service, udev-rules-union, kvm-udev-rule, udev-service,
  device-mapping-service, swap-service): Likewise.
* gnu/services/databases.scm (%default-postgres-hba,
  %default-postgres-ident): Use 'plain-file' instead of 'text-file'.
  (%default-postgres-config): Use 'mixed-text-file' instead of
  'text-file*'.
  (postgresql-service):  Use 'program-file' instead of 'gexp->script'.
  Turn into a regular procedure.
* gnu/services/desktop.scm (dbus-configuration-directory): Use
  'computed-file' instead of 'gexp->derivation'.
  (upower-configuration-file, geoclue-configuration-file,
  elogind-configuration-file): Use 'plain-file' instead of 'text-file'.
  (dbus-service, upower-service, colord-service, geoclue-service,
  polkit-service, elogind-service): Turn into regular procedures.
  (%desktop-services): Remove use of 'mlet' when iterating on
  %BASE-SERVICES.
* gnu/services/lirc.scm (lirc-service): Turn into a regular procedure.
* gnu/services/networking.scm (static-networking-service,
  dhcp-client-service, ntp-service, tor-service, bitlbee-service,
  wicd-service): Likewise.
* gnu/services/ssh.scm (lsh-service): Likewise.
* gnu/services/web.scm (nginx-service): Likewise.
* gnu/services/xorg.scm (xorg-configuration-file): Use 'mixed-text-file'
  instead of 'text-file*'.
  (xorg-start-command, slim-service): Turn into regular procedures.
  (xinitrc): Use 'program-file' instead of 'gexp->script'.
* gnu/system/install.scm (cow-store-service,
  configuration-template-service): Turn into regular procedures.
* gnu/system.scm (other-file-system-services, device-mapping-services,
  swap-services, essential-services, operating-system-services,
  user-shells, operating-system-accounts): Remove now unnecessary
  'mlet' and turn into regular procedures.
  (operating-system-etc-directory, operating-system-activation-script,
  operating-system-boot-script): Adjust accordingly.
* doc/guix.texi (Base Services, Networking Services, X Window, Desktop
  Services, Database Services, Web Services, Various Services, Name
  Service Switch): Adjust accordingly.
2015-10-10 22:46:14 +02:00
Ludovic Courtès ce8a6dfc43 services: 'mingetty-service' no longer takes monadic values.
* gnu/services/base.scm (mingetty-service): Change default value of
  #:motd from a monadic value to a <plain-file>.  Assume MOTD to be a
  file-like object.  Assume LOGIN-PROGRAM is a gexp or #f.
  (%base-services): Use 'plain-file' instead of 'text-file' for motd.
* gnu/system/linux.scm (unix-pam-service): Update docstring to mention
  that MOTD is a file-like object.
* doc/guix.texi (Base Services): Adjust 'mingetty-service' documentation
  accordingly.
* gnu/system/install.scm (installation-services): Adjust accordingly.
  (log-to-info): Use 'program-file' instead of 'gexp->script'.
2015-10-10 22:46:14 +02:00
Ludovic Courtès 0081410da0 Revert "services: 'mingetty-service' no longer takes monadic values."
This reverts commit daa48c3179.
2015-09-13 12:04:55 +02:00
Ludovic Courtès daa48c3179 services: 'mingetty-service' no longer takes monadic values.
* gnu/services/base.scm (mingetty-service): Change default value of
  #:motd from a monadic value to a <plain-file>.  Assume MOTD to be a
  file-like object.  Assume LOGIN-PROGRAM is a gexp or #f.
  (%base-services): Use 'plain-file' instead of 'text-file' for motd.
* gnu/system/linux.scm (unix-pam-service): Update docstring to mention
  that MOTD is a file-like object.
* doc/guix.texi (Base Services): Adjust 'mingetty-service' documentation
  accordingly.
2015-09-13 11:54:56 +02:00
Mark H Weaver 574d9db2ce services: elogind-configuration: Disable hibernation key by default.
* gnu/services/desktop.scm (<elogind-configuration>): Change the default value
  of the 'handle-hibernate-key' field to 'ignore'.
2015-09-10 19:46:30 -04:00
Mark H Weaver 4307c476c4 services: Add udev rules for (upower colord elogind) to %desktop-services.
* gnu/services/desktop.scm (%desktop-services): Replace the 'udev-service'
  from %base-services.
* gnu/services/base.scm (%base-services): Add a comment to keep them in sync.
2015-09-10 19:46:13 -04:00
Andy Wingo 0071c7894e gnu: Add polkit service.
* gnu/services/desktop.scm (polkit-service): New function.
  (%desktop-services): Add polkit service.
2015-09-02 22:34:54 +02:00
Andy Wingo 04463bb05e gnu: Add elogind service.
* gnu/services/desktop.scm (<elogind-configuration>): New record type.
  (elogind-configuration-file, elogind-service): New functions.
  (%desktop-services): Add elogind-service.
2015-09-02 22:22:57 +02:00
David Thompson 58724c488b gnu: services: Add nginx-service.
* gnu/services/web.scm: New file.
* gnu-system.am (GNU_SYSTEM_MODULES): Add it.
* guix.texi ("Web Services"): New section.
2015-08-27 22:10:40 -04:00
Andy Wingo cee32ee4d3 gnu: Add GeoClue desktop service.
* gnu/services/desktop.scm (bool): New top-level helper.
  (upower-configuration-file): Use top-level `bool'.
  (geoclue-application): New public function.
  (%standard-geoclue-applications): New public variable.
  (geoclue-service): New public variable.
  (%desktop-services): Add GeoClue.  Add a comment about activation.
* doc/guix.texi (Desktop Services): Document the GeoClue service.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2015-08-20 17:05:30 +02:00
Mark H Weaver e4fb9d2d97 Revert "PRELIMINARY: dbus-service: Include system-services directories."
This reverts commit e3484421cb.
2015-08-18 23:56:18 -04:00
Mark H Weaver 46c92ea058 Revert "PRELIMINARY: Modify dbus-configuration to find setuid helper."
This reverts commit fe1f2c80a1.
2015-08-18 23:56:15 -04:00
Mark H Weaver fe1f2c80a1 PRELIMINARY: Modify dbus-configuration to find setuid helper. 2015-08-18 23:52:57 -04:00
Mark H Weaver e3484421cb PRELIMINARY: dbus-service: Include system-services directories. 2015-08-18 23:52:57 -04:00
Ludovic Courtès b89e74054e syscalls: Rename 'network-interfaces' and 'all-network-interfaces'.
* guix/build/syscalls.scm (network-interfaces): Rename to...
  (network-interface-names): ... this.
  (all-network-interfaces): Rename to...
  (all-network-interface-names): ... this.
* gnu/services/networking.scm (dhcp-client-service): Adjust accordingly.
* tests/syscalls.scm ("all-network-interfaces"): Rename to...
  ("all-network-interface-names"): ... this, and adjust accordingly.
  ("network-interfaces"): Rename to...
  ("network-interface-names"): ... this, and adjust accordingly.
2015-07-25 14:43:44 +02:00
Ludovic Courtès 68ac258b52 system: Use the CRDA udev rules.
* gnu/services/base.scm (%base-services): Add CRDA to the #:rules of
  'udev-service'.
* gnu/system/install.scm (installation-services): Likewise.
2015-07-17 15:35:57 +02:00
Ludovic Courtès 64720891ae system: Make /dev/kvm 660.
* gnu/services/base.scm (kvm-udev-rule): Change /dev/kvm mode to 0660 as a
  followup to the resolution of <http://bugs.gnu.org/18994>.
2015-07-15 23:57:01 +02:00
Ludovic Courtès 4a3bcaee5a services: Remove lsh service from %DESKTOP-SERVICES.
Suggested by Mark H Weaver and others
at <http://lists.gnu.org/archive/html/guix-devel/2015-06/msg00227.html>.

* gnu/services/desktop.scm (%desktop-services): Remove call to 'lsh-service'.
* doc/guix.texi (Desktop Services): Adjust accordingly.
2015-06-15 17:41:54 +02:00
Ludovic Courtès 60a56db007 services: swap: Use 'restart-on-EINTR'.
* gnu/services/base.scm (swap-service)[start, stop]: Use 'restart-on-EINTR'.
* guix/build/syscalls.scm (swapoff): Fix typo in 'throw' arguments.
2015-05-22 11:51:12 +02:00
Ludovic Courtès c2ee19e685 services: xorg: Add xf86-input-libinput to the server's module path.
* gnu/services/xorg.scm (xorg-configuration-file): Add XF86-INPUT-LIBINPUT.
2015-05-21 22:32:34 +02:00
Ludovic Courtès 1eca6c36ad services: xorg: Assume STARTX is a regular value.
* gnu/services/xorg.scm (slim-service): Expect STARTX to be a regular value,
  not a monadic value.
2015-05-21 22:22:12 +02:00
Ludovic Courtès 12422c9d38 services: xorg: Allow extra config text to be added verbatim.
* gnu/services/xorg.scm (xorg-configuration-file): Add #:extra-config and
  honor it.
* doc/guix.texi (X Window): Adjust accordingly.
2015-05-21 21:33:19 +02:00
Ludovic Courtès d1cdd7ba7a services: xorg: Make 'xorg-configuration-file' public.
* gnu/services/xorg.scm (xorg-configuration-file): New procedure, with code
  formerly in 'xorg-start-command'.
  (xorg-start-command): Remove #:drivers and #:resolutions; add
  #:configuration-file; use it as well as 'xorg-configuration-file'.
2015-05-21 21:33:18 +02:00
Ludovic Courtès 9bb34f9c92 services: dhcp-client: Turn up the interfaces before calling 'dhclient'.
Somehow, as of Linux 4.0.2, the interfaces are down by default, which
prevents 'dhclient' from actually using them.

* gnu/services/networking.scm (dhcp-client-service): Call
  'set-network-interface-up' on each item of IFACES.
2015-05-17 23:24:30 +02:00
Ludovic Courtès c217cbd84d services: dhcp-client: Better track dhclient's PID.
* gnu/services/networking.scm (dhcp-client-service)[start]: Remove
  PID-FILE first.  When 'call-with-input-file' throws ENOENT, try
  again.
2015-05-09 23:53:36 +02:00
Ludovic Courtès 965a733220 doc: Document 'avahi-service'.
* gnu/services/avahi.scm (avahi-service): Add URL in docstring.
* doc/guix.texi (Networking Services): Document it.
  (Name Service Switch): Fix cross-reference.
2015-05-08 16:35:32 +02:00
Ludovic Courtès 04e4e6ab51 doc: Document sessions and ~/.xsession for SLiM.
* gnu/services/xorg.scm (slim-service): Document session types and
  ~/.xsession.
* doc/guix.texi (X Window): Adjust accordingly.
2015-05-08 16:35:32 +02:00
Ludovic Courtès 4467be213a services: Add '%desktop-services'.
* gnu/services/desktop.scm (%desktop-services): New variable.
* doc/guix.texi (Desktop Services): Document it.
2015-05-08 16:35:32 +02:00
Ludovic Courtès cf2abac8ec artwork: Update to latest version.
* gnu/artwork.scm (%artwork-repository): Update.
* gnu/services/xorg.scm (%default-slim-theme-name): Change to "0.x".
* gnu/system/grub.scm (%background-image): Change to
  GuixSD-fully-black-4-3.svg.
2015-05-07 23:11:23 +02:00
David Thompson 105369a46b gnu: Add postgresql-service.
* gnu/services/databases.scm: New file.
* gnu-system.am (GNU_SYSTEM_MODULES): Add it.
* doc/guix.texi ("Database Services"): New subsubsection.
2015-05-07 08:44:36 -04:00
Ludovic Courtès fe1a39d319 services: Group desktop services in (gnu services desktop).
* gnu/services/colord.scm, gnu/services/dbus.scm,
  gnu/services/upower.scm: Remove.
* gnu/services/desktop.scm: New file, with contents taken from the above
  files.
* gnu-system.am (GNU_SYSTEM_MODULES): Adjust accordingly.
* doc/guix.texi (Desktop Services): New section.
  (Various Services): Move colord-service and upower-service from
  here to "Desktop Services".
2015-05-05 22:44:31 +02:00
Alex Kost 5eca94594d services: Add console-keymap service.
* gnu/services/base.scm (console-keymap-service): New procedure.
* doc/guix.texi (Base Services): Document it.

Co-authored-by: 宋文武 <iyzsong@gmail.com>
2015-05-01 21:00:39 +03:00
Ludovic Courtès b86fee7848 file-systems: Use a second 'mount' call for read-only bind mounts.
* gnu/build/file-systems.scm (MS_REMOUNT): New constant.
  (mount-file-system): Add 'flags' local variable.   When FLAGS has
  MS_BIND & MS_RDONLY, call 'mount' with MS_REMOUNT.
* gnu/services/base.scm (file-system-service) <start>: Likewise.
2015-04-20 22:16:13 +02:00
Mark H Weaver 933204e5b1 Merge branch 'master' into core-updates
Conflicts:
	gnu-system.am
	gnu/packages/gstreamer.scm
2015-04-17 09:54:11 -04:00
Ludovic Courtès 5e25ebe2fa services: Explicitly refer to Shadow when requiring the 'nologin' shell.
* gnu/services/avahi.scm (avahi-service): Change 'shell' to a gexp
  referring to "nologin" in the SHADOW package.
* gnu/services/dbus.scm (dbus-service): Likewise.
* gnu/services/networking.scm (ntp-service, tor-service): Likewise.
2015-04-17 13:53:16 +02:00