你在TeamCity中如何设置电子邮件设置?

16

我对TeamCity非常陌生,请多包涵。

我设置了一个电子邮件通知器,以便在构建失败时通知我,但是TeamCity报告以下错误:

无法通过SMTP服务器mail发送电子邮件通知,因为出现错误:Unknown SMTP host: mail;嵌套异常是: java.net.UnknownHostException: mail

我真的找不到在哪里配置邮件服务器设置。我甚至不想它使用SMTP服务器,但是我找不到任何此类选项。

3个回答

16
Option                 Description 
------                 ----------
SMTP host              Specify the SMTP host name.
SMTP port              Specify the SMTP port number.
Send messages from     Specify the email address, from which notification messages will be sent to the user.
SMTP login             Specify the SMTP login name, if any.
SMTP password          Specify the SMTP password.
Use TLS (SSL)          Select this option to secure your SMTP connection with TLS.
                       (This feature is only available in TeamCity 3.1+)
Test connection        Click this button to establish a connection with the specified SMTP host.
Save                   Click this button to save changes and close the page.

来源: http://www.jetbrains.net/confluence/display/TCD3/Email+and+Jabber+Notifier+Settings


啊哈!我能不能不使用电子邮件服务器? - George Mauer
如果你想在构建失败时收到邮件,可能没有什么好办法可以避免使用它。 - Chris Ballance
哇,这需要付出很多努力,而实际上它只是在我自己的机器上运行,为了我的利益。 - George Mauer
如果SMTP在本地运行,请将其设置为回送地址127.0.0.1。 - Chris Ballance
2
我们通过使用Gmail / GoogleApps提供的SMTP服务来避免为TeamCity设置自己的电子邮件服务器。请参见http://www.activecollab.com/forums/topic/3552/。 - dthrasher
@dthrasher 是的,我想过了,但是要么开设一个新的 Gmail 账户,要么使用自己的账户,这两种选择都不是很好。我想等到真正需要设置时再来做吧。 - George Mauer

10

您可以在管理-服务器配置-电子邮件通知下配置您的电子邮件设置。


3

Sumeru的答案(https://dev59.com/hXRB5IYBdhLWcg3wAjRH#825701)描述了您需要设置的邮件帐户,以便TeamCity能够发送电子邮件通知。实际通知是基于每个用户发送的。每个用户可以定义他们希望接收的通知。在TeamCity Professional 7x中,您可以在以下位置执行此操作: 用户名/我的设置和工具/观察的构建和通知/电子邮件通知器


网页内容由stack overflow 提供, 点击上面的
可以查看英文原文,
原文链接