首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >gmail的git-commit-notifier

gmail的git-commit-notifier
EN

Stack Overflow用户
提问于 2010-07-17 11:10:23
回答 1查看 652关注 0票数 1

首先,你要知道我完全是Ruby菜鸟:)

我在我的系统(Ubuntu10.04)上安装了git-commit-notifier (http://github.com/ilozka/git-commit-notifier),并遵循了所有的安装说明,但每次我推送到我的git存储库时,我都会收到以下错误消息:

代码语言:javascript
复制
remote: Sending mail...
remote: /usr/lib/ruby/1.8/net/smtp.rb:944:in `check_auth_response': 530 5.7.0 Must issue a STARTTLS command first. n20sm12555550ibe.5 (Net::SMTPAuthenticationError)
remote:     from /usr/lib/ruby/1.8/net/smtp.rb:735:in `auth_plain'
remote:     from /usr/lib/ruby/1.8/net/smtp.rb:727:in `send'
remote:     from /usr/lib/ruby/1.8/net/smtp.rb:727:in `authenticate'
remote:     from /usr/lib/ruby/1.8/net/smtp.rb:568:in `do_start'
remote:     from /usr/lib/ruby/1.8/net/smtp.rb:527:in `start'
remote:     from /usr/lib/ruby/1.8/net/smtp.rb:465:in `start'
remote:     from /var/lib/gems/1.8/gems/git-commit-notifier-0.7.2/bin/../lib/emailer.rb:42:in `perform_delivery_smtp'
remote:     from /var/lib/gems/1.8/gems/git-commit-notifier-0.7.2/bin/../lib/emailer.rb:96:in `send'
remote:     from /var/lib/gems/1.8/gems/git-commit-notifier-0.7.2/bin/../lib/commit_hook.rb:55:in `run'
remote:     from /var/lib/gems/1.8/gems/git-commit-notifier-0.7.2/bin/../lib/diff_to_html.rb:285:in `each_with_index'
remote:     from /var/lib/gems/1.8/gems/git-commit-notifier-0.7.2/bin/../lib/commit_hook.rb:51:in `each'
remote:     from /var/lib/gems/1.8/gems/git-commit-notifier-0.7.2/bin/../lib/commit_hook.rb:51:in `each_with_index'
remote:     from /var/lib/gems/1.8/gems/git-commit-notifier-0.7.2/bin/../lib/commit_hook.rb:51:in `run'
remote:     from /var/lib/gems/1.8/gems/git-commit-notifier-0.7.2/bin/git-commit-notifier:13
remote:     from /var/lib/gems/1.8/bin/git-commit-notifier:19:in `load'
remote:     from /var/lib/gems/1.8/bin/git-commit-notifier:19

我将错误跟踪到emailer.rb脚本。具体地说,一行:

代码语言:javascript
复制
Net::SMTP.start(settings['address'], settings['port'], settings['domain'],                                                                                                                             
                settings['user_name'], settings['password'], settings['authentication']) do |smtp|

参数传递似乎是正确的(我已经检查过了)。

我的配置脚本如下所示:

代码语言:javascript
复制
# select the delivery method: smtp or sendmail
delivery_method: smtp

# settings for the smtp server
smtp_server:
    address: smtp.gmail.com
    port: 587
    domain: mydomain
    user_name: redmine@mydomain.com
    password: xxxxxx
    authentication: plain
    enable_tls: true

有人知道我如何解决这个问题吗?我在同一台服务器上安装了Redmine,它工作得很好。发送电子邮件没有问题。

谢谢

EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2010-07-18 03:02:11

SMTP似乎不支持STARTTLS。This question通过修补Net::SMTP来解决这个问题。

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

https://stackoverflow.com/questions/3270081

复制
相关文章

相似问题

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