services: syslog-service: Add 'config-file' argument.
* gnu/services/base.scm (syslog-service): Add 'config-file' keyword argument. * doc/guix.texi (Base Services): Document it.
This commit is contained in:
parent
bfe3c68572
commit
1bb76f7523
@ -4508,8 +4508,9 @@ external name servers do not even need to be queried.
|
||||
@end defvr
|
||||
|
||||
|
||||
@deffn {Monadic Procedure} syslog-service
|
||||
Return a service that runs @code{syslogd} with reasonable default
|
||||
@deffn {Monadic Procedure} syslog-service [#:config-file #f]
|
||||
Return a service that runs @code{syslogd}. If configuration file name
|
||||
@var{config-file} is not specified, use some reasonable default
|
||||
settings.
|
||||
@end deffn
|
||||
|
||||
|
@ -526,8 +526,10 @@ given @var{config}---an @code{<nscd-configuration>} object. Optionally,
|
||||
|
||||
(respawn? #f)))))
|
||||
|
||||
(define (syslog-service)
|
||||
"Return a service that runs @code{syslogd} with reasonable default settings."
|
||||
(define* (syslog-service #:key config-file)
|
||||
"Return a service that runs @code{syslogd}.
|
||||
If configuration file name @var{config-file} is not specified, use some
|
||||
reasonable default settings."
|
||||
|
||||
;; Snippet adapted from the GNU inetutils manual.
|
||||
(define contents "
|
||||
@ -561,7 +563,7 @@ given @var{config}---an @code{<nscd-configuration>} object. Optionally,
|
||||
(start
|
||||
#~(make-forkexec-constructor
|
||||
(list (string-append #$inetutils "/libexec/syslogd")
|
||||
"--no-detach" "--rcfile" #$syslog.conf)))
|
||||
"--no-detach" "--rcfile" #$(or config-file syslog.conf))))
|
||||
(stop #~(make-kill-destructor))))))
|
||||
|
||||
(define* (guix-build-accounts count #:key
|
||||
|
Loading…
Reference in New Issue
Block a user