summary refs log tree commit diff
path: root/gnu/services/base.scm
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2020-12-09 11:56:09 +0100
committerLudovic Courtès <ludo@gnu.org>2020-12-09 14:13:32 +0100
commitf066e657132461519de897e695e91e8d381a7a4b (patch)
treec0b0cfe66165bdc4f7e7c164d1693508532dd36d /gnu/services/base.scm
parent59a6780f70e138a515dfe9c3b5b5399dbd91c228 (diff)
downloadguix-f066e657132461519de897e695e91e8d381a7a4b.tar.gz
services: guix-publish: Depend on 'avahi-daemon' when needed.
* gnu/services/base.scm (guix-publish-shepherd-service): Add
'user-processes' to 'requirement'.  When ADVERTISE? is true, also add
'avahi-daemon'.
Diffstat (limited to 'gnu/services/base.scm')
-rw-r--r--gnu/services/base.scm4
1 files changed, 3 insertions, 1 deletions
diff --git a/gnu/services/base.scm b/gnu/services/base.scm
index 709d011f53..8449d924af 100644
--- a/gnu/services/base.scm
+++ b/gnu/services/base.scm
@@ -1825,7 +1825,9 @@ raise a deprecation warning if the 'compression-level' field was used."
           advertise?)
     (list (shepherd-service
            (provision '(guix-publish))
-           (requirement '(guix-daemon))
+           (requirement `(user-processes
+                          guix-daemon
+                          ,@(if advertise? '(avahi-daemon) '())))
            (start #~(make-forkexec-constructor
                      (list #$(file-append guix "/bin/guix")
                            "publish" "-u" "guix-publish"