You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

GitLab配置Office365 SMTP发送测试邮件时出现网络不可达错误求助

GitLab配置Office365 SMTP发送测试邮件时出现网络不可达错误求助

各位大佬好!我刚接触GitLab,最近在上面配置Office365的SMTP服务用来发系统通知邮件,我的配置内容是这样的:

{:authentication=>:login,                         
 :user_name=>"My Email",                  
 :password=>"Email Password",         
 :address=>"smtp.office365.com",
 :port=>587,
 :domain=>"My Domain",
 :enable_starttls_auto=>true,
 :openssl_verify_mode=>"peer",
 :ca_path=>"/etc/ssl/certs",
 :ca_file=>"/etc/ssl/certs/ca-certificates.crt",
 :open_timeout=>30,
 :read_timeout=>60}

结果我发送测试邮件的时候,直接报了网络不可达的错误,折腾了好一会儿都没头绪,错误日志如下:

Delivered mail 6672d26713634_9cc562ee07524@spl-git-server.mail (120201.6ms)
/opt/gitlab/embedded/lib/ruby/3.1.0/socket.rb:1214:in `__connect_nonblock': Network is unreachable - connect(2) for 
[2603:1016:401:2c11::2]:587 (Errno::ENETUNREACH)                                                                            
        from /opt/gitlab/embedded/lib/ruby/...

有没有懂的朋友能指点一下该怎么排查解决这个问题呀?

备注:内容来源于stack exchange,提问作者Yogesh Patel

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.04.16 12:05:28