#!/bin/bash
# 设置收件人邮箱
to="recipient@example.com"
# 设置发件人邮箱
from="sender@example.com"
# 设置邮件主题
subject="Test Email"
# 设置邮件内容
body="This is a test email."
# 发送邮件
echo "${body}" | mail -s "${subject}" -r "${from}" "${to}"
Copyright© 2013-2020
All Rights Reserved 京ICP备2023019179号-8