有着这样的宝石结构:
repo users/CREATOR/.+
C = @defaultgroup
RW+D = CREATOR
RWD = @defaultgroup我们服务器的用户只需克隆“要创建的”回购,就可以轻松地创建自己的存储库--例如:
git clone git@git.exmaple.com/users/foo.bar/new这也出现在我们的gitweb上。但缺少的是一些git配置。我还没有弄清楚如何将工作配置添加到这些新创建的存储库(例如gitweb.url)中。
只是为了比较--这就是“正常”回购的样子:
repo normal/repo
R = @all
RW = @defaultgroup
config gitweb.url = git@git.exmaple.com/normal/repo.git
config receive.denyNonFastforwards = true欢迎任何暗示,干杯。
发布于 2012-10-24 08:53:20
来自海泡石配置页面:
您还可以使用字符串中的特殊值
%GL_REPO和%GL_CREATOR。前者对所有repos都可用,而后者只对野生回购可用。
因此,这个方法可以工作(未经测试):
config gitweb.url = git@git.exmaple.com/%GL_CREATOR/%GL_REPO
config receive.denyNonFastforwards = true(我想最后一行将适用于在repo users/CREATOR/.+下创建的所有野生回复)
https://serverfault.com/questions/441687
复制相似问题