[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

02/04: hydra: services: Allow reading from /var/lib/qa-frontpage.

From: Christopher Baines
Subject: 02/04: hydra: services: Allow reading from /var/lib/qa-frontpage.
Date: Thu, 2 Nov 2023 04:35:21 -0400 (EDT)

cbaines pushed a commit to branch master
in repository maintenance.

commit 8227d5cf56b76f9b9c5ea51d717dab1bf0bef03c
Author: Christopher Baines <>
AuthorDate: Thu Nov 2 08:29:37 2023 +0000

    hydra: services: Allow reading from /var/lib/qa-frontpage.
    Because this will allow NGinx to read and serve specific files from
    this directory.
    * hydra/modules/sysadmin/services.scm (qa-frontpage-activation): New
    (qa-frontpage-service-type): Extend the activation-service-type.
 hydra/modules/sysadmin/services.scm | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/hydra/modules/sysadmin/services.scm 
index d1bf23e..6a5cf0c 100644
--- a/hydra/modules/sysadmin/services.scm
+++ b/hydra/modules/sysadmin/services.scm
@@ -1147,6 +1147,12 @@ to a selected directory.")
            (stop #~(make-kill-destructor))
            (documentation "Run the QA Frontpage.")))))
+(define (qa-frontpage-activation config)
+  (with-imported-modules '((guix build utils))
+    #~(begin
+        (use-modules (guix build utils))
+        (chmod "/var/lib/qa-frontpage" #o755))))
 (define %qa-frontpage-accounts
   (list (user-account
          (name "qa-frontpage")
@@ -1164,6 +1170,8 @@ to a selected directory.")
    (name 'qa-frontpage)
    (extensions (list (service-extension account-service-type
                                         (const %qa-frontpage-accounts))
+                     (service-extension activation-service-type
+                                        qa-frontpage-activation)
                      (service-extension shepherd-root-service-type
    (default-value (qa-frontpage-configuration))

reply via email to

[Prev in Thread] Current Thread [Next in Thread]