[ARVADOS] created: 7f8f29dee43c14ab768d64b7831df8daeda86b21
git at public.curoverse.com
git at public.curoverse.com
Thu Aug 20 01:51:47 EDT 2015
at 7f8f29dee43c14ab768d64b7831df8daeda86b21 (commit)
commit 7f8f29dee43c14ab768d64b7831df8daeda86b21
Author: Tom Clegg <tom at curoverse.com>
Date: Thu Aug 20 01:51:17 2015 -0400
6263: Pass through environment variables needed by gitolite-shell.
diff --git a/services/arv-git-httpd/main.go b/services/arv-git-httpd/main.go
index 452390c..98695c9 100644
--- a/services/arv-git-httpd/main.go
+++ b/services/arv-git-httpd/main.go
@@ -19,7 +19,7 @@ func init() {
flag.StringVar(&theConfig.Addr, "address", "0.0.0.0:80",
"Address to listen on, \"host:port\".")
flag.StringVar(&theConfig.GitCommand, "git-command", "/usr/bin/git",
- "Path to git executable. Each authenticated request will execute this program with a single argument, \"http-backend\".")
+ "Path to git or gitolite-shell executable. Each authenticated request will execute this program with a single argument, \"http-backend\".")
cwd, err := os.Getwd()
if err != nil {
log.Fatalln("Getwd():", err)
diff --git a/services/arv-git-httpd/server.go b/services/arv-git-httpd/server.go
index c3c36da..8adda7b 100644
--- a/services/arv-git-httpd/server.go
+++ b/services/arv-git-httpd/server.go
@@ -19,7 +19,13 @@ func (srv *server) Start() error {
"GIT_PROJECT_ROOT=" + theConfig.Root,
"GIT_HTTP_EXPORT_ALL=",
},
- InheritEnv: []string{"PATH"},
+ InheritEnv: []string{
+ "PATH",
+ // Needed if GitCommand is gitolite-shell:
+ "GITOLITE_HTTP_HOME",
+ "GL_BYPASS_ACCESS_CHECKS",
+ "SERVER_ADDR",
+ },
Args: []string{"http-backend"},
}
mux := http.NewServeMux()
-----------------------------------------------------------------------
hooks/post-receive
--
More information about the arvados-commits
mailing list