首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >Gitlab ssh连接超时(使用Cloudflare和客户端crt)

Gitlab ssh连接超时(使用Cloudflare和客户端crt)
EN

Stack Overflow用户
提问于 2022-08-04 20:57:08
回答 1查看 325关注 0票数 1

我无法连接我的gitlab服务器。webUI使用Cludflare和客户端证书进行保护。但是这并不重要,因为我想和ssh连接。

ssh -Tvvv git@gitlab.domain

代码语言:javascript
复制
OpenSSH_8.9p1 Ubuntu-3, OpenSSL 3.0.2 15 Mar 2022
debug1: Reading configuration data /home/userdir/.ssh/config
debug1: /home/userdir/.ssh/config line 1: Applying options for gitlab.domain
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 19: include /etc/ssh/ssh_config.d/*.conf matched no files
debug1: /etc/ssh/ssh_config line 21: Applying options for *
debug3: expanded UserKnownHostsFile '~/.ssh/known_hosts' -> '/home/userdir/.ssh/known_hosts'
debug3: expanded UserKnownHostsFile '~/.ssh/known_hosts2' -> '/home/userdir/.ssh/known_hosts2'
debug2: resolving "gitlab.domain" port 12345
debug3: resolve_host: lookup gitlab.domain:12345
debug3: ssh_connect_direct: entering
debug1: Connecting to gitlab.domain [123.123.123.123] port 12345.
debug3: set_sock_tos: set socket 3 IP_TOS 0x10
debug1: connect to address 123.123.123.123 port 12345: Connection timed out
debug1: Connecting to gitlab.domain [123.123.123.123] port 12345.
debug3: set_sock_tos: set socket 3 IP_TOS 0x10

~/..ssh/config

代码语言:javascript
复制
Host gitlab.domain
  HostName gitlab.domain
  User gitlabuser
  Port 12345
  PreferredAuthentications publickey
  IdentityFile ~/.ssh/git

(密钥存储在相应的帐户中)

这是什么原因?

EN

回答 1

Stack Overflow用户

发布于 2022-08-05 05:05:50

只要curl -v telnet://gitlab.domain:12345显示超时,就意味着:

在您的计算机之间没有打开网络路由,gitlab.domain:12345

  • or gitlab.domain不监听端口12345

再次检查您的GitLab ssh port configuration,并确保它已启动和运行,使用您需要的端口。

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/73242153

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档