Galaxy send email suddenly stopped working with Mailgun SMTP

Anyone experiencing this?

Tested the same code locally and email sending through Mailgun SMTP worked fine.
Tested using another galaxy app without any recent code changes, and it failed to send from there too.

Just tested from two galaxy apps and the mails fired as expected. We use the mailgun-js npm package and API.

Do you see anything in your mailgun logs?


Thanks for testing, vigor.

I am going through SMTP instead of the API/package.
I’m not seeing the expected emails in the logs.

It works fine when I test locally.

Wondering if Galaxy decided to block SMTP?

Maybe try wrapping your Email.send block in a try catch and log the possible error? Haven’t used this method in a while, but it looks like it should throw an error per the docs.

try {
} catch (err) {

Hi Vigor,

This was already implemented. The console.log in the catch block does not execute. Funny enough, the first Email.send works, then it stops working, even if emailing with the same variables. When I redeploy, it works again, just once.

I looked at the package that you are using. I think maybe best to use that and go through the API.

Thanks Vigor.

Hm, interesting.

I think you’ll find the api much better to work with in the long run than smtp. Plus, you can start batching your messages, working with datasets and variables that mailgun will populate for you, etc.

PM or post back if you have any issues getting started.

1 Like

Thanks Vigor!

It was a pretty painless switch using mailgun-js. The only difference I noticed was the limit of a single attachment per email.

All is working now :relaxed: :thumbsup:

1 Like

Same issue, also went the mailgun-npm route.

1 Like

For anyone else out there, here is the response from Galaxy Support:

Julian Martinez (Meteor Development Group)
Apr 17, 18:07 PDT

Hi Vicky,

Thanks for the update; I spoke to a member of our team, a maintainer of Meteor, who was able to explain the problem in more detail. This was due to a problematic update to the Mailgun package from a community member, that wasn’t sufficiently tested; basically, it would leave connections open too long, causing issues like yours. Our team caught it and fixed it earlier today, and you should now be able to fix the problem (assuming you took no other action) by running meteor update. So the issue was unresolved at the time you wrote in, but has since been patched; let me know if you have any questions about this.


I am having this issue with Meteor Meteor using Mailgun and smtp. First several emails send and then they just stop sending. Re-deploy or container kill and they start sending again… and then stop.

Same issue here…