Commit 9d913789 authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets

Merge pull request #91 from lukasberns/master

Add support for custom SSH ports
parents d5da9d32 a1fff682
...@@ -22,7 +22,11 @@ class Repository ...@@ -22,7 +22,11 @@ class Repository
end end
def url_to_repo def url_to_repo
"#{GITOSIS["git_user"]}@#{GITOSIS["host"]}:#{path}.git" if !GITOSIS["port"] or GITOSIS["port"] == 22
"#{GITOSIS["git_user"]}@#{GITOSIS["host"]}:#{path}.git"
else
"ssh://#{GITOSIS["git_user"]}@#{GITOSIS["host"]}:#{GITOSIS["port"]}/#{path}.git"
end
end end
def path_to_repo def path_to_repo
......
...@@ -2,3 +2,4 @@ admin_uri: git@localhost:gitosis-admin.git ...@@ -2,3 +2,4 @@ admin_uri: git@localhost:gitosis-admin.git
base_path: /home/git/repositories/ base_path: /home/git/repositories/
host: localhost host: localhost
git_user: git git_user: git
# port: 22
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment