Subject: 'herd status' cannot handle inaccessible logfiles (shepherd 1.0.1)

From: Andrew Wong <[email-masked]>
Date: Fri, 7 Feb 2025 15:29:25 -0500

Hello,

I've found a bug in shepherd 1.0.1. When a service has a log file in an 
'inaccessible' location, e.g. a home service logging to /var/log, it 
causes 'herd status $service' to hang, as well as the overall 'herd 
service' command. I found it with this service[1] which silently failed 
to log, I guess, until I updated shepherd and found this bug.

[1]:

(service home-shepherd-service-type
         (home-shepherd-configuration
          (services
           (list
            (shepherd-service
         (provision '(emacs))
         (start #~(make-forkexec-constructor
               (list #$(file-append emacs-pgtk-xwidgets "/bin/emacs")
                 "--fg-daemon")
               #:log-file "/var/log/emacs.log"))
         (stop #~(make-kill-destructor)))))))