i have discourse site on example.com (A record)
i have outgoing emails to Mailgun on discourse.example.com (CNAME / TXT records). I use a Manual SMTP password under username postmaster@discourse.example.com
i have incoming emails to mail-receiver on discourse.example.com (MX record) with Granular API key for System user, and port 443 open so mail-receiver can communicate back through the host (@) discourse site
this DNS setup works perfectly well with O365 Business Basic and the paid plugins from Pavilion