Sending mails from munin using custom command

We use Sendgrid for email delivery on our cloud. Using custom commands in munin can be tricky. After struggling for some timeĀ I wrote a small python script to send emails from munin using sendgrid. Add this line to munin.conf contacts mycontact contact.mycontact.command /usr/bin/sendemail “[Munin] Alert for ${var:host}” “warnings: ${var:wfields} / criticals: ${var:cfields}” contact.mycontact.text text […]