all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* [PATCH 6/7] gnu: Add elogind service.
@ 2015-08-18  9:56 Andy Wingo
  2015-08-21 14:17 ` 宋文武
  0 siblings, 1 reply; 3+ messages in thread
From: Andy Wingo @ 2015-08-18  9:56 UTC (permalink / raw)
  To: guix-devel

* gnu/services/desktop.scm (elogind-service): New function.
  (%desktop-services): Add elogind-service.
---
 gnu/services/desktop.scm | 27 ++++++++++++++++++++++++++-
 1 file changed, 26 insertions(+), 1 deletion(-)

diff --git a/gnu/services/desktop.scm b/gnu/services/desktop.scm
index 4e4b49d..737a734 100644
--- a/gnu/services/desktop.scm
+++ b/gnu/services/desktop.scm
@@ -26,6 +26,7 @@
   #:use-module (gnu system shadow)
   #:use-module (gnu packages glib)
   #:use-module (gnu packages admin)
+  #:use-module (gnu packages freedesktop)
   #:use-module (gnu packages gnome)
   #:use-module (gnu packages avahi)
   #:use-module (gnu packages wicd)
@@ -39,6 +40,7 @@
             geoclue-application
             %standard-geoclue-applications
             geoclue-service
+            elogind-service
             %desktop-services))
 
 ;;; Commentary:
@@ -374,6 +376,28 @@ site} for more information."
 
 \f
 ;;;
+;;; Elogind login and seat management service.
+;;;
+
+(define* (elogind-service #:key (elogind elogind))
+  "Return a service that runs the @command{elogind} login and seat management
+service.  The @command{elogind} service integrates with PAM to allow other
+system components to know the set of logged-in users as well as their session
+types (graphical, console, remote, etc.).  It can also clean up after users
+when they log out."
+  (with-monad %store-monad
+    (return
+     (service
+      (documentation "Run the elogind login and seat management service.")
+      (provision '(elogind))
+      (requirement '(dbus-system))
+
+      (start #~(make-forkexec-constructor
+                (list (string-append #$elogind "/lib/elogind/elogind"))))
+      (stop #~(make-kill-destructor))))))
+
+\f
+;;;
 ;;; The default set of desktop services.
 ;;;
 (define %desktop-services
@@ -389,7 +413,8 @@ site} for more information."
          ;; time, so we currently add them to the set of default services.
          (colord-service)
          (geoclue-service)
-         (dbus-service (list avahi wicd upower colord geoclue))
+         (elogind-service)
+         (dbus-service (list avahi wicd upower colord geoclue elogind))
 
          (ntp-service)
 
-- 
2.4.3

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH 6/7] gnu: Add elogind service.
  2015-08-18  9:56 [PATCH 6/7] gnu: Add elogind service Andy Wingo
@ 2015-08-21 14:17 ` 宋文武
  2015-08-21 14:48   ` Andy Wingo
  0 siblings, 1 reply; 3+ messages in thread
From: 宋文武 @ 2015-08-21 14:17 UTC (permalink / raw)
  To: Andy Wingo, guix-devel

Andy Wingo <wingo@igalia.com> writes:

> * gnu/services/desktop.scm (elogind-service): New function.
>   (%desktop-services): Add elogind-service.
> ---
>  gnu/services/desktop.scm | 27 ++++++++++++++++++++++++++-
>  1 file changed, 26 insertions(+), 1 deletion(-)
>
> diff --git a/gnu/services/desktop.scm b/gnu/services/desktop.scm
> index 4e4b49d..737a734 100644
> --- a/gnu/services/desktop.scm
> +++ b/gnu/services/desktop.scm
> @@ -26,6 +26,7 @@
>    #:use-module (gnu system shadow)
>    #:use-module (gnu packages glib)
>    #:use-module (gnu packages admin)
> +  #:use-module (gnu packages freedesktop)
>    #:use-module (gnu packages gnome)
>    #:use-module (gnu packages avahi)
>    #:use-module (gnu packages wicd)
> @@ -39,6 +40,7 @@
>              geoclue-application
>              %standard-geoclue-applications
>              geoclue-service
> +            elogind-service
>              %desktop-services))
>  
>  ;;; Commentary:
> @@ -374,6 +376,28 @@ site} for more information."
>  
>  \f
>  ;;;
> +;;; Elogind login and seat management service.
> +;;;
> +
> +(define* (elogind-service #:key (elogind elogind))
> +  "Return a service that runs the @command{elogind} login and seat management
> +service.  The @command{elogind} service integrates with PAM to allow other
> +system components to know the set of logged-in users as well as their session
> +types (graphical, console, remote, etc.).  It can also clean up after users
> +when they log out."
> +  (with-monad %store-monad
> +    (return
> +     (service
> +      (documentation "Run the elogind login and seat management service.")
> +      (provision '(elogind))
> +      (requirement '(dbus-system))
> +
> +      (start #~(make-forkexec-constructor
> +                (list (string-append #$elogind
>  "/lib/elogind/elogind"))))
Should be "/libexec/elogind/elogind".
> +      (stop #~(make-kill-destructor))))))
> +
> +\f
> +;;;
>  ;;; The default set of desktop services.
>  ;;;
>  (define %desktop-services
> @@ -389,7 +413,8 @@ site} for more information."
>           ;; time, so we currently add them to the set of default services.
>           (colord-service)
>           (geoclue-service)
> -         (dbus-service (list avahi wicd upower colord geoclue))
> +         (elogind-service)
> +         (dbus-service (list avahi wicd upower colord geoclue elogind))
>  
>           (ntp-service)
>  
> -- 
> 2.4.3
Look good to me!

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH 6/7] gnu: Add elogind service.
  2015-08-21 14:17 ` 宋文武
@ 2015-08-21 14:48   ` Andy Wingo
  0 siblings, 0 replies; 3+ messages in thread
From: Andy Wingo @ 2015-08-21 14:48 UTC (permalink / raw)
  To: 宋文武; +Cc: guix-devel

[-- Attachment #1: Type: text/plain, Size: 365 bytes --]

On Fri 21 Aug 2015 16:17, 宋文武 <iyzsong@gmail.com> writes:

> Look good to me!

Thanks :)  There is a v2 of this patch.  I had to change some paths in
upstream elogind and the path to the binary changed; so if you apply,
apply v2 of the patch please.  Attaching below as I had some mail
weirdness and perhaps it didn't go through.

Cheers,

Andy


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: v2-0006-gnu-Add-elogind-service.patch --]
[-- Type: text/x-patch, Size: 2669 bytes --]

From 7517af974b60a0a3e6ce03d3419863e16edd5999 Mon Sep 17 00:00:00 2001
Message-Id: <7517af974b60a0a3e6ce03d3419863e16edd5999.1440062095.git.wingo@pobox.com>
In-Reply-To: <95cd06d0b1639449fffa2ded823e54d0f26afbb6.1440062095.git.wingo@pobox.com>
References: <95cd06d0b1639449fffa2ded823e54d0f26afbb6.1440062095.git.wingo@pobox.com>
From: Andy Wingo <wingo@pobox.com>
Date: Tue, 18 Aug 2015 11:56:17 +0200
Subject: [PATCH v2 6/7] gnu: Add elogind service.
To: guix-devel@gnu.org

* gnu/services/desktop.scm (elogind-service): New function.
  (%desktop-services): Add elogind-service.
---
 gnu/services/desktop.scm | 27 ++++++++++++++++++++++++++-
 1 file changed, 26 insertions(+), 1 deletion(-)

diff --git a/gnu/services/desktop.scm b/gnu/services/desktop.scm
index 4e4b49d..4973e82 100644
--- a/gnu/services/desktop.scm
+++ b/gnu/services/desktop.scm
@@ -26,6 +26,7 @@
   #:use-module (gnu system shadow)
   #:use-module (gnu packages glib)
   #:use-module (gnu packages admin)
+  #:use-module (gnu packages freedesktop)
   #:use-module (gnu packages gnome)
   #:use-module (gnu packages avahi)
   #:use-module (gnu packages wicd)
@@ -39,6 +40,7 @@
             geoclue-application
             %standard-geoclue-applications
             geoclue-service
+            elogind-service
             %desktop-services))
 
 ;;; Commentary:
@@ -374,6 +376,28 @@ site} for more information."
 
 \f
 ;;;
+;;; Elogind login and seat management service.
+;;;
+
+(define* (elogind-service #:key (elogind elogind))
+  "Return a service that runs the @command{elogind} login and seat management
+service.  The @command{elogind} service integrates with PAM to allow other
+system components to know the set of logged-in users as well as their session
+types (graphical, console, remote, etc.).  It can also clean up after users
+when they log out."
+  (with-monad %store-monad
+    (return
+     (service
+      (documentation "Run the elogind login and seat management service.")
+      (provision '(elogind))
+      (requirement '(dbus-system))
+
+      (start #~(make-forkexec-constructor
+                (list (string-append #$elogind "/libexec/elogind/elogind"))))
+      (stop #~(make-kill-destructor))))))
+
+\f
+;;;
 ;;; The default set of desktop services.
 ;;;
 (define %desktop-services
@@ -389,7 +413,8 @@ site} for more information."
          ;; time, so we currently add them to the set of default services.
          (colord-service)
          (geoclue-service)
-         (dbus-service (list avahi wicd upower colord geoclue))
+         (elogind-service)
+         (dbus-service (list avahi wicd upower colord geoclue elogind))
 
          (ntp-service)
 
-- 
2.4.3


^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2015-08-21 14:48 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-08-18  9:56 [PATCH 6/7] gnu: Add elogind service Andy Wingo
2015-08-21 14:17 ` 宋文武
2015-08-21 14:48   ` Andy Wingo

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.