summaryrefslogtreecommitdiffstats
path: root/roseh.moe.go
diff options
context:
space:
mode:
Diffstat (limited to 'roseh.moe.go')
-rw-r--r--roseh.moe.go6
1 files changed, 5 insertions, 1 deletions
diff --git a/roseh.moe.go b/roseh.moe.go
index 23c13b4..55b3a72 100644
--- a/roseh.moe.go
+++ b/roseh.moe.go
@@ -1104,9 +1104,13 @@ func main() {
http.Handle("code."+*domain+"/cgit.js", cgitStaticFiles)
http.Handle("code."+*domain+"/robots.txt", cgitStaticFiles)
http.HandleFunc("code."+*domain+"/favicon.ico", favicon)
+ cgitConfigAbsPath, err := filepath.Abs(*cgitConfig)
+ if err != nil {
+ log.Fatal(err)
+ }
cgitCGI := &cgi.Handler{
Path: filepath.Join(*cgit, "cgit.cgi"),
- Env: []string{"CGIT_CONFIG=" + *cgitConfig},
+ Env: []string{"CGIT_CONFIG=" + cgitConfigAbsPath},
}
cgitCGI.PathLocationHandler = cgitCGI
http.Handle("code."+*domain+"/", cgitCGI)