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
procedure.
(qa-frontpage-service-type): Extend the activation-service-type.
This commit is contained in:
Christopher Baines 2023-11-02 08:29:37 +00:00
parent 8618fac288
commit 8227d5cf56
No known key found for this signature in database
GPG Key ID: 5E28A33B0B84F577
1 changed files with 8 additions and 0 deletions

View File

@ -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
qa-frontpage-shepherd-services)))
(default-value (qa-frontpage-configuration))