Skip to content

Support alternative mailing services (Mailgun, Mandrill, Sendgrid) - #2649

Merged
aerosol merged 3 commits into
plausible:masterfrom
ruslandoga:more-bamboo-adapters
Feb 7, 2023
Merged

Support alternative mailing services (Mailgun, Mandrill, Sendgrid)#2649
aerosol merged 3 commits into
plausible:masterfrom
ruslandoga:more-bamboo-adapters

Conversation

@ruslandoga

@ruslandoga ruslandoga commented Feb 6, 2023

Copy link
Copy Markdown
Contributor

Changes

This PR is similar to #2596 but hardcodes all adapters that bamboo ships with and adds some config tests.

Tests

  • Automated tests have been added

Changelog

  • Entry has been added to changelog

Documentation

Dark mode

  • This PR does not change the UI

@bundlemon

bundlemon Bot commented Feb 6, 2023

Copy link
Copy Markdown

BundleMon

Unchanged files (7)
Status Path Size Limits
static/css/app.css
515.18KB -
static/js/dashboard.js
297.69KB -
static/js/app.js
12.13KB -
static/js/embed.host.js
5.58KB -
static/js/embed.content.js
5.06KB -
tracker/js/plausible.js
748B -
static/js/applyTheme.js
314B -

No change in files bundle size

Final result: ✅

View report in BundleMon website ➡️


Current branch size history | Target branch size history

Comment thread config/runtime.exs
"Bamboo.MailgunAdapter" ->
config :plausible, Plausible.Mailer,
adapter: Bamboo.MailgunAdapter,
hackney_opts: [recv_timeout: :timer.seconds(10)],

@ruslandoga ruslandoga Feb 6, 2023

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I couldn't find request_options in bamboo. It seems to be specific to bamboo_postmark

So I used hackney_opts in the built-in adapters.

@ruslandoga
ruslandoga marked this pull request as ready for review February 6, 2023 15:17
@ruslandoga
ruslandoga force-pushed the more-bamboo-adapters branch 2 times, most recently from 05c0829 to 237fab9 Compare February 6, 2023 16:22
@ruslandoga
ruslandoga requested review from a team, aerosol and ukutaht and removed request for ukutaht February 6, 2023 16:23
@ruslandoga
ruslandoga force-pushed the more-bamboo-adapters branch 5 times, most recently from 2d9b2db to b5bc0f1 Compare February 6, 2023 17:15
@aerosol aerosol changed the title more bamboo adapters Support alternative mailing services (Mailgun, Mandrill, Sendgrid) Feb 7, 2023
@ruslandoga
ruslandoga force-pushed the more-bamboo-adapters branch from b5bc0f1 to 5a68670 Compare February 7, 2023 10:56
@aerosol
aerosol merged commit 7b2f4c9 into plausible:master Feb 7, 2023
@ruslandoga
ruslandoga deleted the more-bamboo-adapters branch February 7, 2023 17:05
@tenfourty

tenfourty commented May 16, 2023

Copy link
Copy Markdown

Hi folks,
Thank you for this work, it really adds some flexibility for folks wanting to use other services to send email.

In my case I was looking at using this for Mailgun, unfortunately I don't think this will work for folks who use Mailgun's EU servers.

I had a look at the source code for the implementation, and you might need to add the base_uri for Mailgun as well. Mailgun makes a difference in the API base URL between sender domains from within the EU and outside.

You can read more about this in the Bamboo Adapter docs here.

I'll try to put a comment inline to the PR as well.

Do let me know if you want me to create a new issue for this. I felt it was important to include this as this is included in the v2 RC and it would be great to have this fix included.

Of course I might have gotten this completely wrong and if so apologies in case the MAILGUN_BASE_URI variable works (I was going off the test cases in this PR).

@ruslandoga ruslandoga mentioned this pull request May 17, 2023
4 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants