Cannot receive email from gmail
I can telnet to my server and successfully communicate with my mailin instance. I can also see console printouts from these communications on the server side. However, when I send an email from gmail or some other professional client, the mailin server is silent. It doesn't report errors or success. (I have tried multiple log levels, but to no avail.) I know this is not a problem with my server, since I created a simple SMTP server in Python and gmail can send messages to it. The only problem is likely some setup problem with mailin. Has anybody else encountered this problem?
I am using the no-webhook option, and embedding mailin in a node application, as set up in the bottom part of the README. Thanks in advance.
@aashidham what is your node and mailin versions please?
node 0.12.7 mailin 3.0.1
On Sat, Aug 1, 2015 at 1:00 PM, Florent Galland [email protected] wrote:
@aashidham https://github.com/aashidham what is your node and mailin versions please?
— Reply to this email directly or view it on GitHub https://github.com/Flolagale/mailin/issues/47#issuecomment-126949014.
Ping?
Same issue, set disableDNSvalidation, disableDkim, disableSpf to true. Can connect to server, but can't send emails from gmail or any other email client.
The server returns:
550 450 4.1.8 test@domain: Sender address rejected: Domain not found. Docs say disabling DNS validation should be the solution, but I've already done that.
If I just run mailin --webhook, everything works fine. Integrating mailin into my node app is what's causing this.
Ok. We have to double check that there is not a similar issue in https://github.com/andris9/smtp-server. I must admit I have a lot to do with my day to day work right now that's why everything is lagging here.
Thanks for the reply. I'll take a look at the issues in smtp-server. It's funny that everything seems ok when running mailin by itself, but not when integrated in a node app. Is there anything different between the two options?
Good luck with work
There might have very tiny differences in the way we merge the smtp-server options with the options in the mailin constructor. That might come from there!
Ok, found it. There's some inconsistency with the disableDNSValidation flag. In lib/mailin.js on line 39 it's called disableDnsValidation, in the docs it's part of smtpOptions: { disableDNSValidation }, and in cli.js, on line 59, it's disableDNSValidation -- notice capitalization.
What seems to work is:
mailin.start({
disableDNSValidation: true // NOT as part of smtpOptions
})
Well done! The correct one should be disableDNSValidation with DNS upper cased.
Let's wait for the tests, afterwards I'll publish it to npm. https://github.com/Flolagale/mailin/commit/63598715bb33db8d1c5be5606f2ffa7a8510712e