若有 Ticket 或者任何變動, 想要系統自動發送 Email 通知, 可依照此篇的步驟設定.
Web 介面 - 設定電子郵件提醒選項
- 登入後, 點選右上角 "我的帳戶"
- 於 "電子郵件提醒選項" (挑選那些改變需要 Email 通知)
Web 界面 - 整站設定
- 設定 -> 電子郵件提醒選項
- 勾選 選擇欲寄送提醒通知郵件之動作, ex: 問題已新增, 問題已更新
設定 Email 通知
設定 Email 通知步驟如下:
- cp /usr/share/doc/redmine/examples/configuration.yml.example.gz /tmp
- gunzip /tmp/configuration.yml.example.gz
- mv /tmp/configuration.yml.example /etc/redmine/default/email.yml
- sudo chown root:www-data /etc/redmine/default/email.yml
- sudo chmod 640 /etc/redmine/default/email.yml
- 修改設定符合即可. 可參考此篇: Setup Redmine to send email using GMail
production:
delivery_method: :smtp
smtp_settings:
tls: true
address: smtp.gmail.com
port: 25
domain: smtp.gmail.com
authentication: :login
user_name: "user@gmail.com"
password: "password"development:
delivery_method: :smtp
smtp_settings:
address: "localhost"
port: 25 - Localhost 寄信的話, 只需要下述設定即可.
email_delivery:
delivery_method: :smtp
smtp_settings:
address: localhost
port: 25
domain: your.domain.name - 註: 一般到此即完成, 若還有問題, 在繼續往下試試看.
- vim /usr/share/redmine/config/environment.rb
config.action_mailer.perform_deliveries = false
改成
config.action_mailer.perform_deliveries = true - 感謝 clifflu 提醒, 記得安裝 action_mailer_optional_tls 套件
cd /usr/share/redmine
ruby script/plugin install git://github.com/collectiveidea/action_mailer_optional_tls.git - 若未安裝 action_mailer_optional_tls 套件, 會在發信時顯示, 下述錯誤:
530 5.7.0 Must issue a STARTTLS command first