I use docker-mailserver
https://github.com/docker-mailserver/docker-mailserver
It is as simple as a mail server is going to get and runs on the same server as discourse. It doesn’t use a database, keeping the emails in a flat file so not super high volume set up but it works.