Jump to content

WireMail Mailgun


Pierre-Luc
 Share

Recommended Posts

Hi Pierre-Luc

Does this Module with an unverified MailGun domain?

IE where a domain hasn't had any MailGun DNS changes and has simply been added to the MailGun Control panel as a domain?

I'm just testing it with PW 3 and am wondering why it's not working. I've identified and fixed a previous VPS issue.

Link to comment
Share on other sites

Hi Pierre-Luc,

First of all the module is working great for me at the moment. I haven't pushed it to hard yet but has done everything I've asked of it so far.

I have hit a small issue with mailgun and their complaint system and API. 

If people didn't know. If an email recipient accidentally(or on purpose) clicks the "junk" mail button it sends a complaint to Mailgun and they then block you from sending mail to that address, unless you clear/delete the complaint through the API.

As I'm somewhat new to web development, it's hard for me to understand how to even get started.

I was wondering if you or anyone had plans to add a way to administer the complaints from this module? or to check for complaints and delete any that are there before sending the email?

Cheers

  • Like 3
Link to comment
Share on other sites

@ Clarkey1891

Have you had any issues with MailGun's reports dashboard? I notice that although my mails are sending, the stats dashboard doesn't log this. Possibly it's because I'm using an unverified domain (no DNS records have been updated) but wondered if yours was working ?

Link to comment
Share on other sites

I was wondering if you or anyone had plans to add a way to administer the complaints from this module? or to check for complaints and delete any that are there before sending the email?

I'll have to look into Mailgun's webhooks API, and see if it's possible to get incoming notices from this.

Have you had any issues with MailGun's reports dashboard? I notice that although my mails are sending, the stats dashboard doesn't log this. Possibly it's because I'm using an unverified domain (no DNS records have been updated) but wondered if yours was working ?

The stats sometimes take some time to update, but never really long. If you really want to see what's going on, the Logs tab on Mailgun is much more efficient and is pretty much instant.

I would really recommend that you do set your SPF and DKIM, as there are a bunch of penalties on accounts who don't.. https://documentation.mailgun.com/quickstart-sending.html#verify-your-domain

  • Like 2
Link to comment
Share on other sites

@Pierre-Luc

thanks for this module, everything seems to be working well and i greatly appreciate all the time you put into it; Mailgun is great, and i can see myself using it a lot in the future for transactional emails in processwire. :)

My only issues are probably more about adjusting from Mandrill to Mailgun, i do like the Mandrill interface in terms of seeing the outbound activity list, sender, status, subject, view content etc; it's a bit more user friendly; also, this may be how i have it configured but the from address on mailgun shows a "sent by " and then a long email address like person@mg.domain.com ; i know i'm going to get some complaints from clients if that is something that can't be changed, and they may just prefer paying the $10/month mailchimp minimum plan to carry on with Mandrill..

Link to comment
Share on other sites

@Pierre-Luc

thanks for this module, everything seems to be working well and i greatly appreciate all the time you put into it; Mailgun is great, and i can see myself using it a lot in the future for transactional emails in processwire. :)

My only issues are probably more about adjusting from Mandrill to Mailgun, i do like the Mandrill interface in terms of seeing the outbound activity list, sender, status, subject, view content etc; it's a bit more user friendly; also, this may be how i have it configured but the from address on mailgun shows a "sent by " and then a long email address like person@mg.domain.com ; i know i'm going to get some complaints from clients if that is something that can't be changed, and they may just prefer paying the $10/month mailchimp minimum plan to carry on with Mandrill..

My pleasure!

The sent by line usually shows when your DKIM / SPF isn't set, make sure you do.

Link to comment
Share on other sites

ok thanks - i followed their recommendation of the mg subdomain but i guess i need to now add all of the sending domains and dkim records for those domains, at least that's how it is with Mandrill...

Link to comment
Share on other sites

Well you don't really need to have specific email domains unless you expect to have incoming emails through Mailgun. If your main domain has MX records you can just have SPF and DKIM in your TXT entries.

You just need to make sure your outgoing email uses the same domain as the one which is set in your email's "from". When on gmail/gapps with a custom domain for example, it's good to test reception on another domain since Google doesn't like being sent email to an email address "owned" by its own servers but not originating from it and will usually display the originating server as a security measure. It won't generally show on addresses on other domains. The reason it is that way is to prevent address spoofing, since the way email is architected, you can send any email from any server using any email address and nobody would know. As you understand that could have pretty bad consequences in different scenarios, which is why Sender Policy Framework (SPF) and

DomainKeys Identified Mail (DKIM) exist. It might feel annoying and troublesome but in reality it's just good practice. Email is complicated. ;)

  • Like 2
Link to comment
Share on other sites

right i just checked and i do have all of the spf and dkim records correctly done but i think you are saying that i should not use the mg subdomain and change that to the normal domain so i don't get those sent by things..  i wonder if you can have both mailgun and mandrill txt records

Link to comment
Share on other sites

Yep, just change it to the normal domain and it'll show correctly as long as the From address is the same as the MG domain.

What I do worry about, and it is a lesser issue you only run into when switching between WireMail modules, is that they don't all have the same functions or parameters so it's just something to check when you switch. A simple bit of search and replace in your favourite editor and you're sorted though :)

Link to comment
Share on other sites

Yep, just change it to the normal domain and it'll show correctly as long as the From address is the same as the MG domain.

What I do worry about, and it is a lesser issue you only run into when switching between WireMail modules, is that they don't all have the same functions or parameters so it's just something to check when you switch. A simple bit of search and replace in your favourite editor and you're sorted though :)

sure enough, it works like you said! no more 'sent by'...!

good point though about wiremail - i currently use horst's wiremail module and am extensively using the functions for attachments and probably more;

i wonder if when i get to the stage of switching that site over to mailgun, if i'll need to use the SMTP connection option, instead of API..

Link to comment
Share on other sites

  • 2 weeks later...

Hi Luc,

I am not sure if you can help me with this but I'll try anyway...I am using this module to send transaction email for my online store but I am not sure if I got this setup correctly. So my issue is: the email from mailgun is sent straight to spam and after looking into it, there is no mailed-by/sent-by (which I reckon is the issue it went to spam) in the email header. However when I tested it manually using the curl command (as per example here: https://documentation.mailgun.com/quickstart-sending.html#send-via-smtp) on the server (digital ocean) server, it went ok (not being sent to spam).

I also notice when using the curl command the IP address from which the email was sent is Mailgun's IP Address (refer to the details below) but when using this module the IP address is the IP address of the digital ocean ubuntu box. I am not sure which one it should be, but I reckon it should be the IP address of the box and not the mailgun API IP address?

I know this is probably not related to your module direcly but if you can help and potentially point me to the right direction, I really appreciate it. Thank you in advanced!

Mailgun Details

State: Active
IP Address: 209.61.151.224
SMTP Hostname: smtp.mailgun.org
API Base URL: https://api.mailgun.net/v3/v2.weareheim.co
Link to comment
Share on other sites

Hi Luc,

I know what the issue is but I dont know how to solve it and it probably has nothing to do with your module anyway. The issue is the module sends the email using the underlying MTA in my linux box in this case sendmail. Sendmail somehow use the box IP address instead of the IP address of the domain assigned in my mailgun account. I dont really understand how to force sendmail to use mailgun ip address and have been trying here and there but no luck whatsoever.

So, in the end I decided to install exim4 and use smtp settings which works ok. Maybe, I play around with it in the future to resolve this. If anyone here has unix experience with sendmail can point to the direction, really appreciate it. :D

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...