about summary refs log tree commit diff
diff options
context:
space:
mode:
authorArun Isaac2025-08-22 03:35:46 +0100
committerArun Isaac2025-08-22 03:47:57 +0100
commit3c8dc85a584c98bc90088ec1c85933d4d10e7383 (patch)
tree74c9614d976c987f8a5ce8d435494c84da27232c
parent7c017acc1438599e78758f0938078cb85d4b68fc (diff)
downloadguix-forge-3c8dc85a584c98bc90088ec1c85933d4d10e7383.tar.gz
guix-forge-3c8dc85a584c98bc90088ec1c85933d4d10e7383.tar.lz
guix-forge-3c8dc85a584c98bc90088ec1c85933d4d10e7383.zip
laminar: Ensure the nginx user can access the archive directory. HEAD main
-rw-r--r--guix/forge/laminar.scm12
1 files changed, 10 insertions, 2 deletions
diff --git a/guix/forge/laminar.scm b/guix/forge/laminar.scm
index 16f5de7..dcbc5bf 100644
--- a/guix/forge/laminar.scm
+++ b/guix/forge/laminar.scm
@@ -1,5 +1,5 @@
 ;;; guix-forge --- Guix software forge meta-service
-;;; Copyright © 2021–2022, 2024 Arun Isaac <arunisaac@systemreboot.net>
+;;; Copyright © 2021–2022, 2024–2025 Arun Isaac <arunisaac@systemreboot.net>
 ;;;
 ;;; This file is part of guix-forge.
 ;;;
@@ -164,7 +164,15 @@ of @var{<forge-laminar-job>} objects."
                                 (lambda (file stat)
                                   (memq (stat:type stat)
                                         '(regular directory)))
-                                #:directories? #t))))))
+                                #:directories? #t))
+          ;; Ensure the state directory has the right permissions so
+          ;; that the nginx user can get in and serve files from the
+          ;; archive directory. The state directory is the home of the
+          ;; laminar user and is created with more restrictive
+          ;; permissions. So, the permissions need to be overridden.
+          ;; The archive directory, however, is always created with
+          ;; the right permissions.
+          (chmod #$state-directory #o755)))))
 
 (define forge-laminar-service-type
   (service-type