11 ms·
Building a serverless email delivery service on AWS
- ignoramous 5y agoNeat setup there, using SQS to ease up to not hit SES limits. If one wants to go further than just one-off emails, listmonk by Zerodha, a fintech company that builds most of its tech in-house, is pretty decent for an email-list manager. It one-click deploys to Heroku and the only dependency is Postgres. It could use SES as its SMTP server. https://github.com/knadh/listmonk https://github.com/knadh/listmonk
- hardwaresofton 5y agoListmonk is fantastic -- I use it for the newsletter of my own blog and am amazed by how simple it was to set up and how easy it is to operate and use every time I send out a newsletter. Prior to Listmonk I used Mailtrain[0] and like Listmonk so much I want to run it as a service (with 30% donated back to the Listmonk project of course) -- deliverability worries and initial setup aside it's just the kind of minimal tool I've come to love these days. [0]: https://mailtrain.org/ https://mailtrain.org/
- kdasme 5y ago> like Listmonk so much I want to run it as a service (with 30% donated back to the Listmonk project of course) Hey hardwaresofton, this is exactly what we're planning to do on https://srv.io/ https://srv.io/ :) The platform is mostly ready, and we're just finishing some infrastructure changes to allow the platform to run third-party applications safely. We are planning to include Listmonk in a second batch of the applications to release. I personally enjoy working with Listmonk, it has replaced Sendy[0] for me. [0]: https://sendy.co/ https://sendy.co/
- hardwaresofton 5y agoWow that’s an interesting concept! I’ve only ever thought of these services one by one, I hadn’t thought of bundling them under the same service (except when they’re thematically linked like prometheus & jaeger for example). Glad someone else is thinking along the same lines! F/OSS could be so much better with the help of platforms — there’s space for a win win as long as the platform side just pares down the greed a tiny bit.
- ignoramous 5y ago(foss developer here) Just the other day I was wondering why there aren't "software maintainence/repair shops" as there are for hardware (PCs, gadgets, appliances). A tech shop like srv.io is exactly what I was wondering existed. Surely there is a market for it. I wish you (and your competitors) all the very best!
- diskzero 5y agoNice write up. We set up a very similar system using, Serverless instead of SAM, and our costs are about the same. I need to take a good look at MJML. Our templates our stored in S3 and editing them is somewhat primitive.
- Gys 5y agoI really like it for the same reasons as the author. It uses node to compile templates into html, but there is also an API available. Perfect, because my serverside project has no other need for node.
- theshadowknows 5y agoI don’t know how many folks really know how much money is spent by big (and medium and small) companies on sending email but I can tell you it is considerable. My last job was a small retailer and we spent maybe 2m a year just on platform costs and at my current role it’s closer to 200m (USD). There are some places where it probably makes sense to use one of the vendors. But I think a carefully architected custom solution like this could get most organizations where they need to be. I’m just not sure how much the talent costs. Do AWS experts charge a premium? Or would it just be cheaper to buy Acoustic and let the account team handle all the work.
- southerntofu 5y agoFor that kind of money you'll be better off selfhosting your entire infrastructure and employing the "experts".
- chinathrow 5y agoNot so sure about hat. Deliverability is still a huge issue when selfhosting your own e-mail setup.
- southerntofu 5y agoFrom what i saw/experienced deliverability is usually only an issue when spamming people against their will. Sure, Microsoft/Google will block you at first but after a few weeks/months of going through administrative hoops you'll be allowlisted and your mails will deliver just fine. Sounds like paying an office worker a few weeks to keep in touch with Microsoft/Google support plus hardware + employing sysadmins would be considerably cheaper than 200m/year. That is, of course, unless you're spamming your users with undesired messages.
- luckylion 5y agoI'm not so sure. Running transactional-message-only (i.e. double opt-in, password resets) for a small site I own with DKIM and SPF on its own IP for years ... GMail will still block a large percentage of it. Using SES with the exact same emails, Gmail will block significantly less. The large providers are whitelisted and unless you're as large, you're not going to get that privilege. Granted, for $200m you should be large enough to bribe a few Google people to get into the club, but for anything where it reasonably might be profitable to run it yourself and employ a sysadmin, you won't be able to afford that.
- jdthedisciple 5y agoGreat! I literally googled for something like this a couple of months ago.
- urbandw311er 5y agoWe have been using something similar called “Sendy” for a few years now to leverage the cost benefits of AWS and SES. The licence fees are very reasonable and setup instructions are good.
- a_imho 5y agoTitle is misleading, delivery is done by SES which is not built by the author. Might be ignorant here, but to me the article reads like an excuse to use serverless. What I really miss is the testing story though, in my admittedly limited experience with serverless (Lambda and Workers) this was always a pain point I never really managed to overcome.
- suifbwish 5y agoI think an interesting approach would be to send secure email via programmatically generating the public string sequence within a domains TXT DNS record (short time to live expiry) you could even establish a very slow Diffie Hellman key exchange with two paired domains where their TXT records alterations reflect the key exchange. There are multiple dimensions of communication possible here too since you can have a near infinite number of TXT records per domain. You can even in theory transmit TCP packets (albeit slowly) over back and forth DNS modifications. If the encoded info were spread across multiple unrelated domains, it would require any interceptor to know which domains are the carriers of the information. This is pretty similar to blockchain transactions except as long as you have icanns authority to use that domain you control your own private part of the blockchain that is able to interact with any other as long as it operates on the same protocols.
- jerf 5y ago"You can even in theory transmit TCP packets (albeit slowly) over back and forth DNS modifications." More than theory: https://www.google.com/search?hl=en&q=tcp%2Dover%2Ddns https://www.google.com/search?hl=en&q=tcp%2Dover%2Ddns Given as a Google search rather than a concrete link because it's really a rich field. It did take me a few tries to get the right search term.
- throwthere 5y agoSince its primary use is… nefarious? You might find more with searching for dns exfiltration