devroom.io/content/posts/2008-04-09-enabling-trac-email-notifications.md
2019-06-05 14:32:16 +02:00

31 lines
1.4 KiB
Markdown

+++
date = "2008-04-09"
title = "Enabling Trac Email notifications"
tags = ["General", "Trac", "email", "notifications", "tricks"]
slug = "enabling-trac-email-notifications"
+++
If you've ever reported a but to Ruby on Rails, you'll have noticed that their Trac has nice email notification feature. And I bet you want that in your Trac as well!
Now, email notification are nothing exotic. You don't need any plugins, just an outgoing SMTP server and access to your trac.ini file.
In your trac directory open up conf/trac.ini and look for the [notification] header. Make sure you have at least the following settings. Of course, make sure you enter valid values for your situation.
<pre lang="text">always_notify_owner = true
always_notify_reporter = true
always_notify_updater = true
smtp_always_cc = trac-updates@mailinglist # Optional if you want to archive outgoing emails
smtp_enabled = true
smtp_from = trac@ariejan.net
smtp_from_name = Ariejan.net Trac
smtp_replyto = noreply@ariejan.net
smtp_user =
smtp_password =
smtp_server = localhost
smtp_port = 25</pre>
There are a few more options like 'ignore_domains' if you don't want to send emails to certain domains.
Update: good news for you GMail users! There is a 'use_tls' attribute. I think that if you set it to true, you can then specify GMail's SMTP server to send out mails. Of course, a better solution would be to setup Postfix to relay mail to GMail, and just leave Trac to it's default 'localhost' settings.