美文网首页
Shell - 发送邮件

Shell - 发送邮件

作者: Mitchell | 来源:发表于2016-04-27 15:56 被阅读53次
  • 脚本
#!/bin/bash
/usr/sbin/sendmail -t <<EOF
From: <你的邮箱地址>
To: <接收人的邮箱地址>,<接收人的邮箱地址>
Cc: <抄送人的邮箱地址>
Bcc: <私密发送人的邮箱地址>
Subject: $1
_
$2(内容)
_
EOF
  • 运行
./你的脚本文件名称
你的文件名称是 sendmail.sh
./sendmail.sh

相关文章

网友评论

      本文标题:Shell - 发送邮件

      本文链接:https://www.haomeiwen.com/subject/vrpcrttx.html