Epic: Gitlab configuration with default values
This commit is contained in:
parent
b3a0ee8e63
commit
9b337b8328
25 changed files with 147 additions and 45 deletions
|
@ -7,15 +7,11 @@ module Gitlab
|
|||
end
|
||||
|
||||
def self.admin_uri
|
||||
GIT_HOST["admin_uri"]
|
||||
Gitlab.config.git_host.admin_uri
|
||||
end
|
||||
|
||||
def self.url_to_repo(path)
|
||||
if !GIT_HOST["port"] or GIT_HOST["port"] == 22
|
||||
"#{GIT_HOST["git_user"]}@#{GIT_HOST["host"]}:#{path}.git"
|
||||
else
|
||||
"ssh://#{GIT_HOST["git_user"]}@#{GIT_HOST["host"]}:#{GIT_HOST["port"]}/#{path}.git"
|
||||
end
|
||||
Gitlab.config.ssh_path + "#{path}.git"
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue