Hello,

I want to deploy a simple mail server so that it can be used for users to register themselves or reset passwords, etc.

Is there an easy one to deploy (in docker if possible) ?

  • bastion@feddit.nl
    link
    fedilink
    English
    arrow-up
    6
    ·
    6 days ago

    Interesting how you use “simple” and “mail server” in the same sentence.

  • palarith@aussie.zone
    link
    fedilink
    English
    arrow-up
    8
    ·
    edit-2
    6 days ago

    You don’t need a mail server to send emails

    Use an smtp smart host like smtp2go

    • ozzyrockin@lemmy.world
      link
      fedilink
      English
      arrow-up
      1
      ·
      13 hours ago

      +1 to this worked for me, only issue was they block common free emails (like gmails etc) from making accounts but porkbun made it super easy to make a email forward that worked!

  • darklamer@lemmy.dbzer0.com
    link
    fedilink
    English
    arrow-up
    14
    ·
    7 days ago

    As already mentioned several times, selfhosting a mail server is not recommended unless you’re particularly interested in hosting a mail server, but with that said, you might find this project interesting:

    https://maddy.email/

  • MHanak@lemmy.world
    link
    fedilink
    English
    arrow-up
    2
    ·
    5 days ago

    I’d advice against it, aside from spam filters, and it being a general PITA, there is a chance your ISP will block any outgoing mail traffic (in my case orange blocks it)

      • cvf@lemmy.world
        link
        fedilink
        English
        arrow-up
        1
        ·
        edit-2
        4 days ago

        All you need is a local smtp server that relays to another, “real” smtp server. I have a postfix that is configured to use the Proton smtp servers (before that it was Googles). No issues on Telenet.

    • ErwinLottemann@feddit.de
      link
      fedilink
      English
      arrow-up
      2
      ·
      6 days ago

      i self host my mails for almost 20 years now, it was hard work in the beginning, now it’s just a few updates a year. no problem with blacklists or anything, a good hoster is probably beneficial, 10/10 would recommend, even just to learn how all of this works

      • vext01@lemmy.sdf.org
        link
        fedilink
        English
        arrow-up
        2
        ·
        6 days ago

        That’s true. I did learn a lot, but the idea of setting it all up again gives me anxiety.

    • roofuskit@lemmy.world
      link
      fedilink
      English
      arrow-up
      1
      ·
      6 days ago

      I second this comment. It’s been a long time since I set one up and it was a pain. And from what I can tell it’s only gotten harder.

  • pcouy@lemmy.pierre-couy.fr
    link
    fedilink
    English
    arrow-up
    9
    ·
    7 days ago

    Things have been going well for me, using docker-mailserver.

    I followed the setup guide, did everything in the DKIM, DMARC and SPF documentation page. The initial setup required more involvement from me than your standard docker-compose self-hosting deployment, but I got no issues at all (for now, fingers crossed) after the initial setup : I never missed any inbound e-mails, and my outbound e-mails have not been rejected by any spam filter yet.

    However, I agree with everyone else that you should not self-host an important contact address without proper redundancy/recovery mechanism in case anything goes wrong.

    You should also understand that self-hosting an email address means you should never let your domain expire to prevent someone from receiving emails sent to you by registering your expired domain. This means you should probably not use a self-hosted e-mail to register any account on services that may outlive your self-hosted setup because e-mail is frequently used to send password reset links.

  • retro@infosec.pub
    link
    fedilink
    English
    arrow-up
    8
    ·
    7 days ago

    If you need to throw in the towel on email self-hosting, don’t be ashamed. Mail servers are one of the more difficult projects to run. If you do end up outsourcing this, I recommend SendGrid, it’s reliable and free.

  • hperrin@lemmy.world
    link
    fedilink
    English
    arrow-up
    4
    ·
    7 days ago

    This is a can of worms, but you’re probably looking for something like Postfix. Running your own mail server is complicated. You need to set up SPF, DKIM, DMARC, and make sure outbound traffic on port 25 isn’t blocked. You need to check if your IP is on any block lists. You can do that here:

    https://mxtoolbox.com/blacklists.aspx

  • rutrum@lm.paradisus.day
    link
    fedilink
    English
    arrow-up
    2
    ·
    7 days ago

    I used nixos-mailserver with success, and very little configuration. Most of it was dns, and thr guide walked me through it. You would have to a nixos box somewhere though. I spun one up on my vps for it.