services: dovecot: 'stop' method returns #f upon success.

* gnu/services/mail.scm (dovecot-shepherd-service)[stop]: Use 'invoke'
instead of 'make-forkexec-constructor'.  Previously, the 'stop' method
would return the PID of the "dovecot stop" process, which would be
interpreted as a failure to stop the service.
This commit is contained in:
Ludovic Courtès 2020-04-20 22:30:09 +02:00
parent 7d903d2ff7
commit b25ecfa2e0
No known key found for this signature in database
GPG key ID: 090B11993D9AEBB5

View file

@ -1544,9 +1544,10 @@ (define (dovecot-shepherd-service config)
(start #~(make-forkexec-constructor
(list (string-append #$dovecot "/sbin/dovecot")
"-F")))
(stop #~(make-forkexec-constructor
(list (string-append #$dovecot "/sbin/dovecot")
"stop")))))))
(stop #~(lambda _
(invoke #$(file-append dovecot "/sbin/dovecot")
"stop")
#f))))))
(define %dovecot-pam-services
(list (unix-pam-service "dovecot")))