gitolite custom config

This commit is contained in:
Valeriy Sizov 2012-11-07 00:47:33 +02:00
parent be4138af75
commit 0d4568db78
3 changed files with 9 additions and 1 deletions

View file

@ -74,6 +74,7 @@ git_host:
upload_pack: true
receive_pack: true
# host: localhost
# config_file: gitolite.conf
# port: 22
# Git settings

View file

@ -104,6 +104,10 @@ class Settings < Settingslogic
git_host['admin_uri'] || 'git@localhost:gitolite-admin'
end
def gitolite_config_file
git_host['config_file'] || 'gitolite.conf'
end
def gitolite_admin_key
git_host['gitolite_admin_key'] || 'gitlab'
end

View file

@ -14,7 +14,10 @@ module Gitlab
end
def ga_repo
@ga_repo ||= ::Gitolite::GitoliteAdmin.new(File.join(config_tmp_dir,'gitolite'))
@ga_repo ||= ::Gitolite::GitoliteAdmin.new(
File.join(config_tmp_dir,'gitolite'),
conf: Gitlab.config.gitolite_config_file
)
end
def apply