Don’t backup the container!!
Map volumes with your data to physical storage and then simply backup those folders with the rest of your data. Docker containers are already either backed up in your development directory (if you wrote them) or GitHub so like the operating system itself, no need tk backup anything. The whole idea of Docker is the containers are ephemeral. They are reset at every reboot.
Disagree with 99% of the other posts. If you self-host your email it is archived on your system. So-called “private” email isn’t after 6 months in the US. And it is more stable and higher performance to run my own Roundcube webmail on my own server. And I can control the spam filtering. All reasons to host your own.
However there is some “maintenance” involved with unscrupulous black list sites and overzealous email filter software. Google likes to declare basically everything not coming from their buddies as spam Microsoft wants you to kiss the ring. On a work account just this week I tried contacting a German company called Beckhoff and after just 3 “dead” email accounts from previous contacts they decided to ban my entire company (about 100 employees, been in business over 75 years). They also don’t answer their phones. Not sure if they’re still in business or just being German jerks. As a result of their poor performance we may switch to a competitor. I do not put up with that crap.
Also I’m not sure how to phrase this politely but despite promises unless you are using PGP to end-to-end encrypt your email, and even then it’s not 100%, you can’t ever totally make it private. Also it is impossible to totally ensure identity of the sender although we’ve come a long way. Protonmail recently published how they delivered a criminal to the authorities using the small amount of public information they log.
As a result I do agree that you should let someone else deal with the black listers, bans, etc. But I strongly disagree with keeping it on a remote server more than about 10 minutes. That means one of three options (for receiving:
On server dovecot and sendmail work well. Roundcube looks exactly like an improved gmail.
For sending I use smtp2go. At my low usage entire family is free.