gitweb和gitolite无法添加新的回购

She*_*eng 3 git gitolite

我首先安装了gitolite,并添加了一些用户和一些回购,一切都很好.然后我添加了gitweb,并且可以通过apache实例看到repos(只是gitweb,没有gitdaemon).现在出现的问题是我无法再添加新的存储库了.每当我推动更改gitolite-admin conf文件时,日志中总会显示2行

remote: FATAL: git config 'gitweb.description' not allowed
remote: check GIT_CONFIG_KEYS in the rc file
Run Code Online (Sandbox Code Playgroud)

尽管有这两条令人讨厌的线,但每次都会改变conf文件.我试图阻止apache实例,但仍然没有运气:-(

我用谷歌搜索,找不到任何类似的匹配来讨论这个问题.有人可以帮忙吗?非常感谢!

Von*_*onC 5

Gitolite G2,G3迁移页提到:

现在转到您的旧克隆,然后推送它:

$ cd old.ga
$ gitolite push -f
    ...usual git progress output deleted...
remote: FATAL: git config foo.bar not allowed
remote: check GIT_CONFIG_KEYS in the rc file
To /home/git/repositories/gitolite-admin.git
 + 7eb8163...1474770 master -> master (forced update)
Run Code Online (Sandbox Code Playgroud)

AAHA!我忘了在新的rc文件中设置GIT_CONFIG_KEYS(新名称GL_GITCONFIG_KEYS),所以修复:

$ vim ~/.gitolite.rc
(edit and set it to `.*` for now)
Run Code Online (Sandbox Code Playgroud)

确保您.gitolite.rc的确包含:

GIT_CONFIG_KEYS             =>  '.*',
Run Code Online (Sandbox Code Playgroud)

(在这个GitLab问题中也提到过,即使它不是问题的直接根本原因)


我有另一个问题,projects.list当我向gitolite-adminconf 添加一个新的存储库时,我的文件没有自动更新.
对于gitweb,我不得不手动编辑该文件.你知道可能导致什么吗?

" 与外部工具接口 "页面提到:

gitweb可读repos列表被写入一个文件,其名称由rc文件变量给出GITWEB_PROJECTS_LIST.
此变量的默认值(如果未指定或为空)为$HOME/projects.list.

确保你有.gitolite.rc:

GITWEB_PROJECTS_LIST        => '/path/to/projects.list',
Run Code Online (Sandbox Code Playgroud)