I'm just getting into managing servers and am enjoying myself tinkering with things. Right now, I have a domain name and a private server hosting my website on said domain. Right now I'd like to set up email so I can have whatever@mydomain.com be my email address. However, I've got too much tied to my current gmail account to abandon it, so now I'm looking for a way to send email as whatever@mydomain.com from gmail and simply forward all email received by whatever@mydomain.com to my gmail account. I have no idea what I'm doing here, so if I'm saying something that doesn't make any sense... well... correct me :)
What I have:
A gmail account
A server (with Ubuntu Server and nginx)
A domain name
A DNS with (MX) records I can edit
What I want:
(Part 1) Very simple, minimal resource system on my server that allows me to receive email at whatever@mydomain.com, and immediately forwards that to my gmail account. (Part 2) I also want to be logged into my gmail account and be able to send email as whatever@mydomain.com. I want all email transmitted and received by my server to be encrypted (I have an SSL certificate, if that's necessary). I don't want to be able to log into my mail server and check my email that way (through a web client). I only want to interact with it through my gmail account. Basically, I don't even want to know (from a usability standpoint) that my server exists. Also, I don't want to do any spam filtering, as I expect gmail to take care of that.
What I think I need to do (but have no idea if I'm headed in the right direction):
For part 1, I think I need to setup some kind of mail proxy server (correct me if I'm wrong!). From what little googling I've done, I've heard nice things about Postfix, but am still completely unsure of what to do. For part 2, I'm sure I need to set up my proxy to use SMTP, but again, that all depends on what program I've chosen to act as my proxy.
My question:
Do you have any direction you can offer me on this? I'm not even sure if an email proxy is what I want, so if you can at least tell me the words I should be googling or the right name of things I should be using, that would help a lot. Is Postfix able to be a simple, thin mail proxy?