mirror of
https://git.in.rschanz.org/ryan77627/guix.git
synced 2024-12-24 21:38:07 -05:00
services: guix-publish: Configure log rotation.
* gnu/services/base.scm (%guix-publish-log-rotations): New variable. (guix-publish-service-type): Extend the rottlog-service-type.
This commit is contained in:
parent
b09793172f
commit
4252dace19
1 changed files with 7 additions and 0 deletions
|
@ -28,6 +28,7 @@ (define-module (gnu services base)
|
||||||
#:use-module (guix store)
|
#:use-module (guix store)
|
||||||
#:use-module (guix deprecation)
|
#:use-module (guix deprecation)
|
||||||
#:use-module (gnu services)
|
#:use-module (gnu services)
|
||||||
|
#:use-module (gnu services admin)
|
||||||
#:use-module (gnu services shepherd)
|
#:use-module (gnu services shepherd)
|
||||||
#:use-module (gnu system pam)
|
#:use-module (gnu system pam)
|
||||||
#:use-module (gnu system shadow) ; 'user-account', etc.
|
#:use-module (gnu system shadow) ; 'user-account', etc.
|
||||||
|
@ -1838,6 +1839,10 @@ (define %guix-publish-accounts
|
||||||
(home-directory "/var/empty")
|
(home-directory "/var/empty")
|
||||||
(shell (file-append shadow "/sbin/nologin")))))
|
(shell (file-append shadow "/sbin/nologin")))))
|
||||||
|
|
||||||
|
(define %guix-publish-log-rotations
|
||||||
|
(list (log-rotation
|
||||||
|
(files (list "/var/log/guix-publish.log")))))
|
||||||
|
|
||||||
(define (guix-publish-activation config)
|
(define (guix-publish-activation config)
|
||||||
(let ((cache (guix-publish-configuration-cache config)))
|
(let ((cache (guix-publish-configuration-cache config)))
|
||||||
(if cache
|
(if cache
|
||||||
|
@ -1859,6 +1864,8 @@ (define guix-publish-service-type
|
||||||
guix-publish-shepherd-service)
|
guix-publish-shepherd-service)
|
||||||
(service-extension account-service-type
|
(service-extension account-service-type
|
||||||
(const %guix-publish-accounts))
|
(const %guix-publish-accounts))
|
||||||
|
(service-extension rottlog-service-type
|
||||||
|
(const %guix-publish-log-rotations))
|
||||||
(service-extension activation-service-type
|
(service-extension activation-service-type
|
||||||
guix-publish-activation)))
|
guix-publish-activation)))
|
||||||
(default-value (guix-publish-configuration))
|
(default-value (guix-publish-configuration))
|
||||||
|
|
Loading…
Reference in a new issue