System mail

From Notes to self
Revision as of 20:28, 6 August 2022 by Verbovet (talk | contribs)
Jump to navigation Jump to search
  • /etc/msmtprc
account default
from hostname@ejik.org
host smtp.yandex.ru
port 465
auth on
tls on
tls_starttls off
tls_trust_file /etc/ssl/certs/ca-certificates.crt
user <smtp-user@example.net>
password <password>

aliases /etc/aliases
  • /etc/aliases
default: user@ejik.org
  • Add to the end of /etc/nail.rc:
set from="hostname <hostname@ejik.org>"
  • # ln -s /usr/bin/msmtp /usr/sbin/sendmail
  • If using mdadm, add to /etc/mdadm.conf:
MAILADDR root
MAILFROM "hostname <hostname@ejik.org>"