Attached is a manifest file which allows a user to write a shepherd-service like the following:
(define redshift-service
(shepherd-service
(provision '(redshift))
(modules `((gnu packages xdisorg)
,@%default-modules))
(start #~(make-forkexec-constructor
(list (string-append #$redshift "/bin/redshift")
"-l" "50:4")))))
And transform it into a package:
(services->package (list redshift-service))
This allows it to be included in a user's profile. This unites the
definition of a service with its dependencies (redshift, in the example
above). A user would not have to install a package just to use it as a
service, nor would they have to hand-write a Shepherd configuration
file.
It may be desired to add services->package and my edited version of
shepherd-configuration-file to Guix. I have not written a patch, though,
because I am unsure where it should go and some FIXMEs remain. Feedback
would be much appreciated!
user-services.scm
Description: Binary data
