sSMTP 資料一覧
GmailのSMTPサーバを使ってsSMTPでroot宛のメールを送信する設定
2015/07/04更新
対応バージョン: 2.64-8
GmailのSMTPサーバを使ってsSMTPでroot宛のメール(cronジョブの結果など)を送信するには以下のようなシンプルな設定を行えばよい。
/etc/ssmtp/ssmtp.conf
root=<Gmailアカウント>@gmail.com mailhub=smtp.gmail.com:587 UseSTARTTLS=YES AuthUser=<Gmailアカウント>@gmail.com AuthPass=<パスワード>
メールを送信すると/var/log/mail.logには以下のようなログが記録される。
sSMTP[xxx]: Creating SSL connection to host sSMTP[xxx]: SSL connection using RSA_ARCFOUR_128_SHA1 sSMTP[xxx]: Sent mail for xxx@xxx (221 2.0.0 closing connection qiweoz8011164x0d.78 - gsmtp) uid=xxx username=xxx outbytes=xxx
関連資料・記事