aboutsummaryrefslogtreecommitdiff
path: root/gitosis/run_hook.py
diff options
context:
space:
mode:
authorTommi Virtanen <tv@eagain.net>2007-11-29 00:40:34 +0200
committerTommi Virtanen <tv@eagain.net>2007-11-29 00:40:34 +0200
commit2078a0c828a064d0e12eed9110c3f71237a3d022 (patch)
tree73f85e3d7b887241e78508f253cfbac9e317ec01 /gitosis/run_hook.py
parentAdd instructions for using gitweb. (diff)
downloadgitosis-dakkar-2078a0c828a064d0e12eed9110c3f71237a3d022.tar.gz
gitosis-dakkar-2078a0c828a064d0e12eed9110c3f71237a3d022.tar.bz2
gitosis-dakkar-2078a0c828a064d0e12eed9110c3f71237a3d022.zip
Write gitweb projects.list to ~/gitosis, not inside the gitosis-admin repo.
This allows running gitweb as a separate user without needing to allow it read access to gitosis-admin.git. Running as separate user will still most likely require a ``chgrp www-data`` of the relevant repositories, but nothing not already decided public needs to be exposed. Existing gitweb users will need to adjust their gitweb.conf to point to the new location of the projects.list file. Removing the old projects.list from ~git/repositories/gitosis-admin.git/projects.list is safe once gitweb has switched to using the new location.
Diffstat (limited to 'gitosis/run_hook.py')
-rw-r--r--gitosis/run_hook.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/gitosis/run_hook.py b/gitosis/run_hook.py
index a7943fc..f9a009d 100644
--- a/gitosis/run_hook.py
+++ b/gitosis/run_hook.py
@@ -13,6 +13,7 @@ from gitosis import ssh
from gitosis import gitweb
from gitosis import gitdaemon
from gitosis import app
+from gitosis import util
def post_update(cfg, git_dir):
export = os.path.join(git_dir, 'gitosis-export')
@@ -31,9 +32,10 @@ def post_update(cfg, git_dir):
gitweb.set_descriptions(
config=cfg,
)
+ generated = util.getGeneratedFilesDir(config=cfg)
gitweb.generate_project_list(
config=cfg,
- path=os.path.join(git_dir, 'projects.list'),
+ path=os.path.join(generated, 'projects.list'),
)
gitdaemon.set_export_ok(
config=cfg,