mirror of
https://git.in.rschanz.org/ryan77627/guix.git
synced 2025-01-11 21:59:08 -05:00
services: dbus: Deprecate 'dbus-service' procedure.
* doc/guix.texi (Desktop Services): Replace with 'dbus-root-service-type'. Document dbus-configuration. * gnu/services/dbus.scm (dbus-service): Define with 'define-deprecated'. * gnu/services/desktop.scm (desktop-services-for-system): Replace with dbus-root-service-type. * gnu/system/install.scm (%installation-services): Ditto. * gnu/tests/base.scm (%avahi-os): Ditto. * gnu/tests/docker.scm (%docker-os): Ditto. * gnu/tests/lightdm.scm (minimal-desktop-services): Ditto. * gnu/tests/virtualization.scm (%libvirt-os): Ditto. Signed-off-by: Ludovic Courtès <ludo@gnu.org>
This commit is contained in:
parent
7c23dab85c
commit
2799ad4423
8 changed files with 38 additions and 24 deletions
|
@ -23301,24 +23301,37 @@ The actual service definitions included in @code{%desktop-services} and
|
||||||
provided by @code{(gnu services dbus)} and @code{(gnu services desktop)}
|
provided by @code{(gnu services dbus)} and @code{(gnu services desktop)}
|
||||||
are described below.
|
are described below.
|
||||||
|
|
||||||
@deffn {Scheme Procedure} dbus-service [#:dbus @var{dbus}] [#:services '()] @
|
@defvar dbus-root-service-type
|
||||||
[#:verbose?]
|
Type for a service that runs the D-Bus ``system bus''.
|
||||||
Return a service that runs the ``system bus'', using @var{dbus}, with
|
@footnote{@uref{https://dbus.freedesktop.org/, D-Bus} is an inter-process
|
||||||
support for @var{services}. When @var{verbose?} is true, it causes the
|
communication facility. Its system bus is used to allow system services
|
||||||
@samp{DBUS_VERBOSE} environment variable to be set to @samp{1}; a
|
to communicate and to be notified of system-wide events.}
|
||||||
verbose-enabled D-Bus package such as @code{dbus-verbose} should be
|
|
||||||
provided as @var{dbus} in this scenario. The verbose output is logged
|
|
||||||
to @file{/var/log/dbus-daemon.log}.
|
|
||||||
|
|
||||||
@uref{https://dbus.freedesktop.org/, D-Bus} is an inter-process communication
|
The value for this service type is a @code{<dbus-configuration>} record.
|
||||||
facility. Its system bus is used to allow system services to communicate
|
@end defvar
|
||||||
and to be notified of system-wide events.
|
|
||||||
|
|
||||||
@var{services} must be a list of packages that provide an
|
@deftp {Data Type} dbus-configuration
|
||||||
@file{etc/dbus-1/system.d} directory containing additional D-Bus configuration
|
Data type representing the configuration for @code{dbus-root-service-type}.
|
||||||
and policy files. For example, to allow avahi-daemon to use the system bus,
|
|
||||||
@var{services} must be equal to @code{(list avahi)}.
|
@table @asis
|
||||||
@end deffn
|
@item @code{dbus} (default: @code{dbus}) (type: file-like)
|
||||||
|
Package object for dbus.
|
||||||
|
|
||||||
|
@item @code{services} (default: @code{()}) (type: list)
|
||||||
|
List of packages that provide an @file{etc/dbus-1/system.d} directory
|
||||||
|
containing additional D-Bus configuration and policy files.
|
||||||
|
For example, to allow avahi-daemon to use the system bus, @var{services}
|
||||||
|
must be equal to @code{(list avahi)}.
|
||||||
|
|
||||||
|
@item @code{verbose?} (default: @code{#f}) (type: boolean)
|
||||||
|
When @code{#t}, D-Bus is launched with environment variable
|
||||||
|
@samp{DBUS_VERBOSE} set to @samp{1}. A verbose-enabled D-Bus package
|
||||||
|
such as @code{dbus-verbose} should be provided to @var{dbus} in this
|
||||||
|
scenario. The verbose output is logged to
|
||||||
|
@file{/var/log/dbus-daemon.log}.
|
||||||
|
|
||||||
|
@end table
|
||||||
|
@end deftp
|
||||||
|
|
||||||
@subsubheading Elogind
|
@subsubheading Elogind
|
||||||
|
|
||||||
|
|
|
@ -38,7 +38,7 @@ (define-module (gnu services dbus)
|
||||||
#:export (dbus-configuration
|
#:export (dbus-configuration
|
||||||
dbus-configuration?
|
dbus-configuration?
|
||||||
dbus-root-service-type
|
dbus-root-service-type
|
||||||
dbus-service
|
dbus-service ; deprecated
|
||||||
wrapped-dbus-service
|
wrapped-dbus-service
|
||||||
|
|
||||||
polkit-configuration
|
polkit-configuration
|
||||||
|
@ -245,7 +245,8 @@ (define dbus-root-service-type
|
||||||
bus. It allows programs and daemons to communicate and is also responsible
|
bus. It allows programs and daemons to communicate and is also responsible
|
||||||
for spawning (@dfn{activating}) D-Bus services on demand.")))
|
for spawning (@dfn{activating}) D-Bus services on demand.")))
|
||||||
|
|
||||||
(define* (dbus-service #:key (dbus dbus) (services '()) verbose?)
|
(define-deprecated (dbus-service #:key (dbus dbus) (services '()) verbose?)
|
||||||
|
dbus-root-service-type
|
||||||
"Return a service that runs the \"system bus\", using @var{dbus}, with
|
"Return a service that runs the \"system bus\", using @var{dbus}, with
|
||||||
support for @var{services}. When @var{verbose?} is true, it causes the
|
support for @var{services}. When @var{verbose?} is true, it causes the
|
||||||
@samp{DBUS_VERBOSE} environment variable to be set to @samp{1}; a
|
@samp{DBUS_VERBOSE} environment variable to be set to @samp{1}; a
|
||||||
|
|
|
@ -1880,7 +1880,7 @@ (define* (desktop-services-for-system #:optional
|
||||||
(service geoclue-service-type)
|
(service geoclue-service-type)
|
||||||
(service polkit-service-type)
|
(service polkit-service-type)
|
||||||
(service elogind-service-type)
|
(service elogind-service-type)
|
||||||
(dbus-service)
|
(service dbus-root-service-type)
|
||||||
|
|
||||||
(service ntp-service-type)
|
(service ntp-service-type)
|
||||||
|
|
||||||
|
|
|
@ -442,7 +442,7 @@ (define bare-bones-os
|
||||||
(list %loopback-static-networking))
|
(list %loopback-static-networking))
|
||||||
|
|
||||||
(service wpa-supplicant-service-type)
|
(service wpa-supplicant-service-type)
|
||||||
(dbus-service)
|
(service dbus-root-service-type)
|
||||||
(service connman-service-type
|
(service connman-service-type
|
||||||
(connman-configuration
|
(connman-configuration
|
||||||
(disable-vpn? #t)))
|
(disable-vpn? #t)))
|
||||||
|
|
|
@ -962,7 +962,7 @@ (define %avahi-os
|
||||||
(name-service-switch %mdns-host-lookup-nss)
|
(name-service-switch %mdns-host-lookup-nss)
|
||||||
(services (cons* (service avahi-service-type
|
(services (cons* (service avahi-service-type
|
||||||
(avahi-configuration (debug? #t)))
|
(avahi-configuration (debug? #t)))
|
||||||
(dbus-service)
|
(service dbus-root-service-type)
|
||||||
(service dhcp-client-service-type) ;needed for multicast
|
(service dhcp-client-service-type) ;needed for multicast
|
||||||
|
|
||||||
;; Enable heavyweight debugging output.
|
;; Enable heavyweight debugging output.
|
||||||
|
|
|
@ -48,7 +48,7 @@ (define-module (gnu tests docker)
|
||||||
(define %docker-os
|
(define %docker-os
|
||||||
(simple-operating-system
|
(simple-operating-system
|
||||||
(service dhcp-client-service-type)
|
(service dhcp-client-service-type)
|
||||||
(dbus-service)
|
(service dbus-root-service-type)
|
||||||
(service polkit-service-type)
|
(service polkit-service-type)
|
||||||
(service elogind-service-type)
|
(service elogind-service-type)
|
||||||
(service docker-service-type)))
|
(service docker-service-type)))
|
||||||
|
|
|
@ -49,7 +49,7 @@ (define minimal-desktop-services
|
||||||
(service accountsservice-service-type)
|
(service accountsservice-service-type)
|
||||||
(service polkit-service-type)
|
(service polkit-service-type)
|
||||||
(service elogind-service-type)
|
(service elogind-service-type)
|
||||||
(dbus-service)
|
(service dbus-root-service-type)
|
||||||
x11-socket-directory-service))
|
x11-socket-directory-service))
|
||||||
|
|
||||||
(define %lightdm-os
|
(define %lightdm-os
|
||||||
|
|
|
@ -49,7 +49,7 @@ (define-module (gnu tests virtualization)
|
||||||
(define %libvirt-os
|
(define %libvirt-os
|
||||||
(simple-operating-system
|
(simple-operating-system
|
||||||
(service dhcp-client-service-type)
|
(service dhcp-client-service-type)
|
||||||
(dbus-service)
|
(service dbus-root-service-type)
|
||||||
(service polkit-service-type)
|
(service polkit-service-type)
|
||||||
(service libvirt-service-type)))
|
(service libvirt-service-type)))
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue