User Tools

Site Tools


утилита_msmtp

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
утилита_msmtp [2020/12/12 18:13]
val создано
утилита_msmtp [2025/04/03 13:13] (current)
val
Line 1: Line 1:
 ====== Утилита msmtp ====== ====== Утилита msmtp ======
  
 +  * [[https://​gist.github.com/​movd/​7a9e3db63d076f85d16c7dcde62fe401|Setting up email with SMTP on Ubuntu/​Debian Servers]]
  
 +<​code>​
 +# apt install msmtp
 +
 +# cat /​etc/​msmtprc
 +</​code><​code>​
 +defaults
 +port 25
 +tls off
 +#tls on
 +auth off
 +
 +account default
 +
 +host mail.isp.un
 +domain server.corpX.un
 +#from asterisk@server.corpX.un ​ #need for mutt
 +
 +#host server.corpX.un
 +#domain corpX.un
 +#from root@lan.corpX.un
 +#aliases /​etc/​aliases
 +</​code><​code>​
 +$ cat mail.txt
 +</​code><​code>​
 +Content-Type:​ text/plain; charset=UTF-8
 +To: userX@isp.un
 +From: Asterisk <​asterisk@server.corpX.un>​
 +Subject: Record
 +Запись
 +cделана
 +</​code><​code>​
 +cat mail.txt | msmtp -f asterisk@server.corpX.un userX@isp.un
 +</​code>​
 +
 +==== Утилита mail без mta ====
 +
 +<​code>​
 +# apt install msmtp-mta bsd-mailx
 +
 +# cat /​etc/​msmtprc
 +...
 +
 +# cat /​etc/​aliases
 +...
 +
 +# newaliases
 +
 +# mail root
 +</​code>​
утилита_msmtp.1607785989.txt.gz · Last modified: 2020/12/12 18:13 by val