1
0
mirror of https://git.savannah.gnu.org/git/guix.git synced 2026-05-18 15:15:54 +02:00

services: git-http-nginx-location-configuration: Add gitconfig.

* gnu/services/version-control.scm (git-http-nginx-location-configuration):
Specify a global gitconfig that marks git-root as a safe directory.

Fixes: guix/guix#3649
Change-Id: I503cd05e3247a71a4bd07df49c276e04d3a43a81
Signed-off-by: Mathieu Othacehe <othacehe@gnu.org>
This commit is contained in:
Evgeny Pisemsky
2025-10-26 20:22:23 +03:00
committed by Mathieu Othacehe
parent 93805c657b
commit 2899ed6d9d
+5
View File
@@ -6,6 +6,7 @@
;;; Copyright © 2018 Christopher Baines <mail@cbaines.net>
;;; Copyright © 2021 Julien Lepiller <julien@lepiller.eu>
;;; Copyright © 2025 Tomas Volf <~@wolfsden.cz>
;;; Copyright © 2025 Evgeny Pisemsky <mail@pisemsky.site>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -248,6 +249,10 @@ access to exported repositories under @file{/srv/git}."
"fastcgi_param GIT_HTTP_EXPORT_ALL \"\";"
"")
(list "fastcgi_param GIT_PROJECT_ROOT " git-root ";")
(list "fastcgi_param GIT_CONFIG_GLOBAL "
(plain-file "gitconfig"
(string-append "[safe]\n\tdirectory = " git-root "/*\n"))
";")
"fastcgi_param PATH_INFO $1;"))))))