求救 gitlab收不到注册邮件

vfish 发布于 2017/09/04 10:14
阅读 485
收藏 0

配置了gitlab,能用下面这条命令发送邮件成功,但是在注册页面,新用户注册没有邮件,而且/var/log/maillog 没有日志输出。

irb(main):003:0> Notify.test_email('destination_email@address.com', 'Message Subject', 'Message Body').deliver_now

/etc/gitlab/gitlab.rb 的配置

gitlab_rails['smtp_enable'] = true
 gitlab_rails['smtp_address'] = "smtp.exmail.qq.com"
 gitlab_rails['smtp_port'] = 465
 gitlab_rails['smtp_user_name'] = "xxx@xx.com"
 gitlab_rails['smtp_password'] = "!qazXS2"
 gitlab_rails['smtp_authentication'] = "login"
 gitlab_rails['smtp_enable_starttls_auto'] = true
 gitlab_rails['smtp_tls'] = true
 gitlab_rails['gitlab_email_from'] = 'xxx@xxx.com'
 

加载中
0
小黄鸭的思想
小黄鸭的思想

1.检查QQ是否开启了SMTP

2.检查服务器网络是否能连到SMTP地址

 

v
vfish
网络都没问题,可以telnet通smtp端口和网络
0
Andy_xu
Andy_xu

关闭smtp_tls 使用25端口试试看,还有看看你邮箱有没有启用安全,如果启用安全密码应该是要到邮箱上去生成一大串的哪个密码

v
vfish
还是收不到, 这个是 tail 的日志 ==> /var/log/gitlab/gitlab-rails/production.log <== Started POST "/users/confirmation" for 192.168.2.191 at 2017-09-04 06:40:34 -0400 Processing by ConfirmationsController#create
0
v
vfish

==> /var/log/gitlab/gitlab-rails/production.log <==
Started POST "/users/confirmation" for 192.168.2.191 at 2017-09-04 06:40:34 -0400
Processing by ConfirmationsController#create as HTML
  Parameters: {"utf8"=>"✓", "authenticity_token"=>"nld88fqbk8GLTHxcgWi0nE+Nm/fv3AkfHVOqUBF+FpzbOtrN8zW3qrGXTGtZ97hT47/r8bJxPD8hBIz5bodMyA==", "user"=>{"email"=>"117001301@qq.com"}}
[ActiveJob] Enqueued ActionMailer::DeliveryJob (Job ID: 7e74b54f-a7ed-4f0b-b0f0-f9f124f37b4f) to Sidekiq(mailers) with arguments: "DeviseMailer", "confirmation_instructions", "deliver_now", gid://gitlab/User/1, "LJZ3yvXXuRhAczDQ75jH", {:to=>"117001301@qq.com"}
 

0
v
vfish

用 gitlab-ce-9.5.2-ce.0.el7.x86_64 安装可以收到邮件,

gitlab-ce-9.5.3-ce.0.el7.x86_64.rpm 用这个安装收不到邮件

但在注册的时候还是收不到邮件,只有在设置里面修改邮箱可以收到邮件

返回顶部
顶部