So, I’m trying to set up a self-hosted mastodon instance, and of course this requires an email service. Self hosting one is not an option, because of anti-spam stuff, or so everyone says. The recommendations are to use services like mailgun or postmark, but there’s one thing I don’t really understand:

All these services require verification of an email to be able to send from it. For example, if I want to use noreply[at]mydomain.com with mailgun, I need to click a link sent to that address, which to me feels like a catch-22. How can I receive that email if I don’t have the email service set up yet? Do I have to set the domain up with some private email service (protonmail, tuta…) first?

Any help is appreciated, I’m pretty new at this.

Edit: Alright, so it seems that Mailgun actually doesn’t require this weird confirmation email, just dns records. The first one I tried, SendPulse, did. Postmark requires an email from the domain at signup. Hope someone else can learn from this.

9 points

It’s not that self hosting email is impossible, just that it takes a lot of work to set up correctly and keep up with spam and abuse prevention. You can literally just fire up postfix, add a DNS record, and you’re up and running. The problem is none of the major providers will talk to you until you add SPF, DKIM, and DMARK (including the appropriate DNS records), and if you don’t have controls in place to immediately shut down any spammer attempts then those services will blacklist you. It can get exhausting after awhile, especially dealing with providers like Microsoft who make you go through impossible hoops to get access to monitor their view of your domain, but then their tools don’t actually show any incidents which cause them to blacklist you.

You might be able to just set up a quick local mail server for your domain in order to receive those confirmation messages, but I would suggest taking a closer look at exactly what you’re trying to get set up for, or maybe contact the companies directly. You might not actually be in the right area to sign up for a service to handle all the email for your domain, and a company rep could possibly point you to the right spot or explain to you how you’re supposed to receive a confirmation email when no email service exists yet.

permalink
report
reply
4 points

Idk what mailgun is doing, but many services verify your domain by having you add a specific TXT DNS record or automatic verification by logging into Cloudflare (if that’s where your Domains at) or something

permalink
report
reply
1 point
*

Do you have any specific recommendations?

ETA: A lot of the services I’ve seen even require signing up with a custom domain, meaning I can’t even get past that stage (well, I could use my personal domain I guess, but I’d rather not).

permalink
report
parent
reply
1 point

Are you trying to avoid taking out another domain and use a service that offers free subdomains so it’s like noreply[at]yourinstance.service.com?

I don’t know of any specific service, but I would just take out another domain, they’re pretty cheap for .com and .net over at Cloudflare

permalink
report
parent
reply
2 points
*

There are a few all-in-one solutions out there that make selfhosting Email easier. “Mailcow” for example if you’re using docker.

Maybe your provider also offers you mail.

I think you can also register an external mail service. For example register an email address with gmail.com and set SMTP_SERVER SMTP_LOGIN and SMTP_PASSWORD etc accordingly. You then need to set SMTP_FROM_ADDRESS to the gmail address. I dont think it’ll work with noreply@mydomain.com if you’re doing it like that.

permalink
report
reply
2 points

I use protonmail + porkbun domain + postmark, and it works great.

permalink
report
reply
2 points

Some domain registrars have cheap or even free email services, OVH for example gives a single email address for free with each domain, which is very likely to be sufficient for most self-hosting needs.

permalink
report
reply

Self Hosted - Self-hosting your services.

!selfhost@lemmy.ml

Create post

A place to share alternatives to popular online services that can be self-hosted without giving up privacy or locking you into a service you don’t control.

Rules

  • No harassment
  • crossposts from c/Open Source & c/docker & related may be allowed, depending on context
  • Video Promoting is allowed if is within the topic.
  • No spamming.
  • Stay friendly.
  • Follow the lemmy.ml instance rules.
  • Tag your post. (Read under)

Important

Beginning of January 1st 2024 this rule WILL be enforced. Posts that are not tagged will be warned and if not fixed within 24h then removed!

  • Lemmy doesn’t have tags yet, so mark it with [Question], [Help], [Project], [Other], [Promoting] or other you may think is appropriate.

Cross-posting

If you see a rule-breaker please DM the mods!

Community stats

  • 118

    Monthly active users

  • 380

    Posts

  • 2.6K

    Comments