systemd-email (254B)
1 #!/usr/bin/env bash 2 # Send email trough systemd 3 4 msmtp -C /etc/msmtprc $1 <<ERRMAIL 5 To: $1 6 From: systemd <maton+$HOSTNAME@sbr.me> 7 Subject: $2 8 Content-Transfer-Encoding: 8bit 9 Content-Type: text/plain; charset=UTF-8 10 11 $(systemctl status --full "$2") 12 ERRMAIL