#!/bin/sh set -e # If SMTP vars are provided, write an msmtp config for authenticated SMTP if [ -n "${SMTP_HOST:-}" ]; then : "${SMTP_PORT:=587}" : "${SMTP_FROM:=noreply@example.com}" : "${SMTP_TLS:=on}" cat > /etc/msmtprc <