diff options
| author | Arun Isaac <arunisaac@systemreboot.net> | 2026-05-20 20:29:36 +0100 |
|---|---|---|
| committer | Arun Isaac <arunisaac@systemreboot.net> | 2026-05-29 09:48:26 +0100 |
| commit | b8354c29794d36ddc87f467f79ee4583f9f36107 (patch) | |
| tree | 67e6e01bec3c7a8956a12c374a6e9a9297bcc0ed /gnu/services | |
| parent | 33036b2908f598ff1f106c1b5ee4ca9e6c16eb2d (diff) | |
services: mumi: Make rsync and index timer event configurable.
* gnu/services/web.scm (<mumi-configuration>)[rsync-and-index-event]: New
field.
* gnu/services/web.scm (mumi-shepherd-services): Use it.
* doc/guix.texi (Web Services)[Mumi]: Document it.
Change-Id: I5910c4a93106b44eaf3900d6a72fb501c01b8773
Diffstat (limited to 'gnu/services')
| -rw-r--r-- | gnu/services/web.scm | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/gnu/services/web.scm b/gnu/services/web.scm index 112c4c0af3b..81e6509e085 100644 --- a/gnu/services/web.scm +++ b/gnu/services/web.scm | |||
| @@ -329,6 +329,7 @@ | |||
| 329 | mumi-configuration-data-directory | 329 | mumi-configuration-data-directory |
| 330 | mumi-configuration-rsync-remote | 330 | mumi-configuration-rsync-remote |
| 331 | mumi-configuration-rsync-flags | 331 | mumi-configuration-rsync-flags |
| 332 | mumi-configuration-rsync-and-index-event | ||
| 332 | mumi-configuration-mailer? | 333 | mumi-configuration-mailer? |
| 333 | mumi-configuration-sender | 334 | mumi-configuration-sender |
| 334 | mumi-configuration-smtp | 335 | mumi-configuration-smtp |
| @@ -2355,6 +2356,9 @@ WSGIPassAuthorization On | |||
| 2355 | (rsync-remote mumi-configuration-rsync-remote) | 2356 | (rsync-remote mumi-configuration-rsync-remote) |
| 2356 | (rsync-flags mumi-configuration-rsync-flags | 2357 | (rsync-flags mumi-configuration-rsync-flags |
| 2357 | (default '())) | 2358 | (default '())) |
| 2359 | (rsync-and-index-event mumi-configuration-rsync-and-index-event | ||
| 2360 | ;; Run every 5 minutes by default. | ||
| 2361 | (default #~(calendar-event #:minutes '#$(iota 12 0 5)))) | ||
| 2358 | (mailer? mumi-configuration-mailer? (default #t)) | 2362 | (mailer? mumi-configuration-mailer? (default #t)) |
| 2359 | (sender mumi-configuration-sender (default #f)) | 2363 | (sender mumi-configuration-sender (default #f)) |
| 2360 | (smtp mumi-configuration-smtp (default #f)) | 2364 | (smtp mumi-configuration-smtp (default #f)) |
| @@ -2465,7 +2469,7 @@ WSGIPassAuthorization On | |||
| 2465 | "/lib/locale"))) | 2469 | "/lib/locale"))) |
| 2466 | 2470 | ||
| 2467 | (match-record config <mumi-configuration> | 2471 | (match-record config <mumi-configuration> |
| 2468 | (mumi mailer? sender smtp) | 2472 | (mumi rsync-and-index-event mailer? sender smtp) |
| 2469 | (list (shepherd-service | 2473 | (list (shepherd-service |
| 2470 | (provision '(mumi)) | 2474 | (provision '(mumi)) |
| 2471 | (documentation "Mumi bug-tracking web interface.") | 2475 | (documentation "Mumi bug-tracking web interface.") |
| @@ -2482,9 +2486,7 @@ WSGIPassAuthorization On | |||
| 2482 | (provision '(mumi-rsync-and-index)) | 2486 | (provision '(mumi-rsync-and-index)) |
| 2483 | (modules '((shepherd service timer))) | 2487 | (modules '((shepherd service timer))) |
| 2484 | (start #~(make-timer-constructor | 2488 | (start #~(make-timer-constructor |
| 2485 | ;; Run every 5 minutes, unless an instance of | 2489 | #$rsync-and-index-event |
| 2486 | ;; this job is already running. | ||
| 2487 | (calendar-event #:minutes '#$(iota 12 0 5)) | ||
| 2488 | (command (list #$(mumi-rsync-and-index config))) | 2490 | (command (list #$(mumi-rsync-and-index config))) |
| 2489 | #:log-file #$%mumi-rsync-and-index-log | 2491 | #:log-file #$%mumi-rsync-and-index-log |
| 2490 | #:max-duration (* 2 60 60) | 2492 | #:max-duration (* 2 60 60) |
