【发布时间】:2014-04-08 03:37:07
【问题描述】:
溢出!由于我是新来的,并决定第一次自己问一个问题,我希望我是按照指导方针提出的。如有错误请指出。
Can't clone gitlab's repo via ssh, via http - OK
我的问题与那个问题非常相似,但我想确保我的配置中没有任何可能导致它的简单错误。
我的设置是 Ubuntu 12.10 和 GitLab 6.0.2
HTTP 克隆完美运行,但使用 SSH SmartGit 会永远加载(“检查与存储库的连接”),直到弹出消息“等待以下过程完成:git.exe ls-remote git@git.server.com: groupname/projectname.git refs/heads/*"
/home/git/gitlab$ sudo -u git -H bundle exec rake gitlab:check RAILS_ENV=production
说一切都好:
Checking Environment ...
Git configured for git user? ... yes Has python2? ... yes python2 is supported version? ... yes
Checking Environment ... Finished
Checking GitLab Shell ...
GitLab Shell version >= 1.7.0 ? ... OK (1.7.0) Repo base directory exists? ... yes Repo base directory is a symlink? ... no Repo base owned by git:git? ... yes Repo base access is drwxrws---? ... yes post-receive hook up-to-date? ... yes post-receive hooks in repos are links: ... groupname / projectname ... ok
Checking GitLab Shell ... Finished
Checking Sidekiq ...
Running? ... yes
Checking Sidekiq ... Finished
Checking GitLab ...
Database config exists? ... yes Database is SQLite ... no All migrations up? ... yes GitLab config exists? ... yes GitLab config outdated? ... no Log directory writable? ... yes Tmp directory writable? ... yes Init script exists? ... yes Init script up-to-date? ... yes Projects have satellites? ... groupname / projectname ... yes Redis version >= 2.0.0? ... yes Your git bin path is "/usr/bin/git" Git version >= 1.7.10 ? ... yes (1.7.10)
Checking GitLab ... Finished
每次我尝试通过 SSH 登录时,auth.log 都会添加:
sshd[processID]: Set /proc/self/oom_score_adj to 0
sshd[processID]: Connection from CLIENTIP port xxxx
第一行是什么意思?第二行中的端口似乎在 6000 和 8000 之间变化。如果我禁用防火墙,也会出现同样的问题。我在路由器上转发了端口 22,并尝试通过 lan 访问存储库。
使用 PuTTY 我可以通过 SSH 连接,以用户“git”的身份使用密码和密钥登录。登录后,我从 gitlab 收到一条消息“欢迎来到 GitLab,名字姓氏!”紧接着“连接被远程主机关闭。”
我被困在这一点上。我应该发布我的 sshd.conf 吗?如果您能指出正确的方向,我将不胜感激。
感谢阅读!
【问题讨论】:
-
看到不同的端口是正常的。客户端在其端选择一个随机端口来发送数据。