this post was submitted on 31 Jul 2023
24 points (92.9% liked)

Selfhosted

40219 readers
1106 users here now

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:

  1. Be civil: we're here to support and learn from one another. Insults won't be tolerated. Flame wars are frowned upon.

  2. No spam posting.

  3. Posts have to be centered around self-hosting. There are other communities for discussing hardware or home computing. If it's not obvious why your post topic revolves around selfhosting, please include details to make it clear.

  4. Don't duplicate the full text of your blog or github here. Just post the link for folks to click.

  5. Submission headline should match the article title (don’t cherry-pick information from the title to fit your agenda).

  6. No trolling.

Resources:

Any issues on the community? Report it using the report flag.

Questions? DM the mods!

founded 1 year ago
MODERATORS
 

Hi there,

what SMTP relay's / services do you use or can recommend for sending monitoring alerts.

I'm running a few services, but mostly all my custom scripts, and tasks are configured to sent an e-mail if something goes "off-script". Before I used my gmail account - but I'm in the middle of migrating away, and my requirements have evolved.

I've searched but I haven't found anything good. Services like Mailgun, Mailtrap etc. are nice - but their bundle's are a bit much for my taste.

The service/ relay should meet the following requirements.

  • bring your own domain (use your own domain/ or sub-domains as sender address)
  • must have DKIM (anything else is not a serious service!)
  • support SMTP via TLS
  • support multiple SMTP clients, with each different credentials/ secrets
  • Allow custom header/ envelope changes

At the moment I'm looking at Amazon SES, because I don't expect a lot of messages (I had 3 alerts in the last 1,5 yrs).

top 23 comments
sorted by: hot top controversial new old
[–] gsrfan01@lemmy.world 4 points 1 year ago

I’ve been using SMTP2Go at work for our low volume of notifications and it works fantastic

[–] somedaysoon@lemmy.world 4 points 1 year ago* (last edited 1 year ago) (2 children)

I know this doesn't fit your criterea OP, but if anyone else is looking for some kind of notification service, I use: SMTP to Telegram

I get instantly notified on my phone for healthchecks.io failures, cronjob reports for different scripts like borg backups or ddns update failures, certain Home Assistant scripts, and Sonarr completions so I know when a new TV episode is done downloading, and a bunch of other things set to notify on failure like SMART failures or snapraid-runner failures or distro updates... so many things. It's nice having peace of mind that if I haven't been notified that something is wrong, then I know everything is working, and I do not need to check on it. So it's one of my favorite services that I'm running.

I don't think I need to say it, but this is obviously not something you would put facing WAN as there is no TLS nor authentication.

[–] thejoker8814@lemmy.world 2 points 1 year ago

Even if it's a bit different. It's always nice to see what's out there. I will definitively look into it.

[–] leaf@feddit.nl 1 points 1 year ago (1 children)
[–] somedaysoon@lemmy.world 1 points 1 year ago* (last edited 1 year ago)

That looks very nice, gives a lot more options which I love so I will have to look into it.

[–] SirMaple_@lemmy.world 3 points 1 year ago

I use mailrise which is apprise under the hood for anything that doesn't have Pushover support built into it. Mailrise converts any email it receives to a push message. It supports a ton of different services like Pushover.

https://github.com/YoRyan/mailrise

[–] influence1123@psychedelia.ink 3 points 1 year ago* (last edited 1 year ago) (1 children)

I am in the exact same boat. I just switched to Proton as it looked like they had these features right away. But it turns out you have to explain what you want to use smtp for before they allow you to generate tokens. Which is probably due to them attracting a high amount of scammers due to their really good privacy. So I can understand but it is a tad annoying. If you are willing to wait I'd give them a try. Their business plan is cheaper than googles and gives you a lot and they are open source.

[–] thejoker8814@lemmy.world 2 points 1 year ago (1 children)

Good to know, thank you. I looked into proton for my primary mail account, but I didn't think of it for that purpose.

[–] influence1123@psychedelia.ink 2 points 1 year ago

Nevermind. After days of back and forth with them they said that they only have that feature available to big companies that have an account with them for a year or more, which is definitely annoying. I'm going to give Brevo a shot next, I heard someone mention them in a thread before about this. It looks like their free tier allows for 300 emails a day. I'll let you know how that goes if you are still looking.

[–] node815@lemmy.world 2 points 1 year ago (1 children)

I use Purelymail for mine. I have Uptime Kuma integrated with it using the SMTP server and also have different things like my password vault connected through it. It's generally lightning fast and budget friendly too.

[–] thejoker8814@lemmy.world 1 points 1 year ago

It sounds very promising.

Thanks. I really appreciate all those “niche” products. With just web research I wouldn’t have found it.

[–] bmck@lemmy.bmck.au 2 points 1 year ago (1 children)

SES is pretty solid and easy to work with. Free for small email volumes like your use case.

You need to verify your domain and request production access explaining your use-case. If you're only sending to known recipients, you can just verify them and not worry about the "production access".

[–] veloxy@lemmy.world 1 points 1 year ago (1 children)

A little note on that: Amazon SES free tier is going to change starting tomorrow though. It changed from free to free for 12 months (with adjusted limits), see https://devclass.com/2023/06/23/aws-to-remove-62000-message-simple-email-service-always-free-tier-from-august-2023/

[–] bmck@lemmy.bmck.au 1 points 1 year ago

After the pricing change, I believe it's still free (or negligible) for low email traffic.

5,000 emails per month are still free, at $0.07 per 1,000 after that.

[–] delendum@lemdit.com 2 points 1 year ago (1 children)

Have you thought of self-hosting mailcow? https://github.com/mailcow/mailcow-dockerized

It's very easy to set up and fairly straightforward to maintain, if you have a static IP and it's not impossible to get a PTR record then I highly recommend it. Yes you're self hosting your own mail server but mailcow vastly simplifies this.

Alternatively plonking it on the right VPS can also work.

[–] thejoker8814@lemmy.world 1 points 1 year ago

I thought about self-hosting, but first of all I got a dynamic IP. Further I want a solution which has roughly 98% availability and 99,99% reliability, because this service tells me if everything burns/ goes awry. That's not the service I'd like to "toy" with. And hosting any kind of mail service with 98% availability and 99,99% reliability, automatic DKIM roll-over etc. is a tough nut. Even VPS cost's seem higher than just Amazon SES.

[–] exu@feditown.com 1 points 1 year ago* (last edited 1 year ago) (1 children)

I use mailgun at the moment. Still free for me and I send 2-3 mails per day. I had problems once with some mails not arriving or landing in spam, but that was fixed after a day or so.

Edit: Just checked the dashboard and I'm getting 1000 mails per month for free. Can't find exactly where they offer this plan anymore though, so they might have removed that.

[–] thejoker8814@lemmy.world 1 points 1 year ago

Was signed up there as well, when they started like years ago. But I couldn’t get back into their free tier.

[–] nothacking@discuss.tchncs.de 1 points 1 year ago (1 children)

For alerts I just have the server directly send email over SMTP to my address, no service needed. You could implement DKIM with such a setup if you wanted to.

[–] thejoker8814@lemmy.world 2 points 1 year ago (1 children)

Sure - but that would be another thing to self-host - because I have at least 5 machines which need to send, and I have a dynamic IP address - so it would involve updating the MX records via DNS API for at least 5 sub domains.

To be honest, I'm a KISS kind of guy - not everything technical possible or imaginable is worthwhile. Especially if it's such a crucial part like alert monitoring. I want it done simple, secure, without caveats and keeping the complexity on the lowest level possible.

[–] wgs@lemmy.sdf.org 2 points 1 year ago* (last edited 1 year ago) (1 children)

Most distro provide either EXIM or Postfix installed by default, and configured to send outbound emails from localhost. All you need to do is start the service, change /etc/aliases to add root: and run newaliases.

You don't need MX records for that. MX is only needed to receive emails on a domain. Worst case is your monitoring emails will end up in spam (because there's no SPF configured for your machine), but your spam filter will eventually accept them as you move them from the spam folder to inbox.

Pretty KISS in my opinion. More than changing all your apps to use an external relay, setup accounts, yada yada...

[–] thejoker8814@lemmy.world 1 points 1 year ago (1 children)

My bad, I meant SPF record.

I have some issue with just that, all emails will end up in a spam filter (if your mail provider is thorough). Also your IP might end up on a public spam/ block list. To much to go wrong, in case some alerts need to reach me.

Plus I use a strict DMARC, so at least a correct SPF is needed.

I’m using postfix on my machines, all services send to it and it just to relays via a SMTP service. So only one point to configure.

I was specifically looking for the last part, a SMTP relay service.

[–] wgs@lemmy.sdf.org 1 points 1 year ago

As you please ;)

Be aware that I've been doing that for all my servers for the past 5 years and it works like a charm. I run OpenBSD, and only need to rcctl start smtpd to start sending outbound emails.

They're all sent from "root@host.domain.tld", which have neither SPF nor DMARK records, and end up in my inbox no problem (I use spamassassin as my spam filter). They won't end up on Blocklist as the volume is just waaayyyyyyy too low anyway.