Configuring the mail server under linux is difficult because:
1. mail servers under linux can do a lot, they can service thousands of clients over lan and in other configurations,
2. security certificates are a story of their own, and they need to work well with the mail server.
That is why to learn how to configure a mail server under linux takes weeks rather than days.
However, I managed to make postfix send mail (but I failed to make fetchmail receive mail) with this:
https://help.ubuntu.com/community/GmailPostfixFetchmail