The basics for this is quite simple. I once used this article to get started (found with a google search)
http://brianbrunner.com/automation/postfix/email/2013/09/09/postfix.html -- Sent from: http://postfix.1071664.n5.nabble.com/Postfix-Users-f2.html