diff options
author | Marius Bakke <mbakke@fastmail.com> | 2018-08-16 20:56:38 +0200 |
---|---|---|
committer | Marius Bakke <mbakke@fastmail.com> | 2018-08-16 20:56:38 +0200 |
commit | df570bf271536399993b39e7ea2ea0452bb6cde4 (patch) | |
tree | 32cde458f90c599691831fc33cfbd4efcca9e9eb /gnu/services/messaging.scm | |
parent | 37d203985e2817b0962129384e8b993a1bb92de9 (diff) | |
parent | 5f9a9945b5747e5ec284f8b116b2e8cc1b9064d7 (diff) | |
download | guix-df570bf271536399993b39e7ea2ea0452bb6cde4.tar.gz |
Merge branch 'master' into staging
Diffstat (limited to 'gnu/services/messaging.scm')
-rw-r--r-- | gnu/services/messaging.scm | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/gnu/services/messaging.scm b/gnu/services/messaging.scm index 4b7e724a78..1108006411 100644 --- a/gnu/services/messaging.scm +++ b/gnu/services/messaging.scm @@ -632,13 +632,20 @@ See also @url{https://prosody.im/doc/modules/mod_muc}." (opaque-prosody-configuration-prosody config) (prosody-configuration-prosody config))) (prosodyctl-bin (file-append prosody "/bin/prosodyctl")) + (pid-file (prosody-configuration-pidfile config)) (prosodyctl-action (lambda args #~(lambda _ - (zero? (system* #$prosodyctl-bin #$@args)))))) + (invoke #$prosodyctl-bin #$@args) + (match '#$args + (("start") + (call-with-input-file #$pid-file read)) + (_ #t)))))) (list (shepherd-service (documentation "Run the Prosody XMPP server") (provision '(prosody xmpp-daemon)) (requirement '(networking syslogd user-processes)) + (modules `((ice-9 match) + ,@%default-modules)) (start (prosodyctl-action "start")) (stop (prosodyctl-action "stop")))))) |