Leo Famulari <[email protected]> writes:

> I noticed that MPD 0.19.21 adds a systemd service file for unprivileged
> users:
>
> http://git.musicpd.org/cgit/master/mpd.git/plain/NEWS?h=v0.19.21
>
> It works for me! 
>
> This patch installs both the privileged and unprivileged service files.
>
> I wonder, is this installation path correct? Should they be at
>
> ~/.guix-profile/etc/systemd[...] (my patch does this)

Yes. Unit names in managed packages should not conflict, so no further
namespacing necessary. This way users can just sync/link units from
<guix-profile>/etc/systemd/{user,system} to the respective system
locations.

Btw, Shepherd works in user mode too ;-)

Here is a config that defines a service for "mcron":

$ cat ~/.config/shepherd/init.scm
(define mcron (make <service>
                    #:provides '(mcron)
                    #:start (make-forkexec-constructor
                             (list "/run/current-system/profile/bin/mcron"))
                    #:stop (make-kill-destructor)))
(register-services mcron)

I guess it would be better to re-use the Guix service definition, but
haven't gotten that far yet.

Attachment: signature.asc
Description: PGP signature

Reply via email to