Closed jon-whit closed 9 years ago
Did you run node bin/configure.js
?
If so, it probably means your email creds are not correct. What you using to send your email? A gmail account?
Indeed, I did run node bin/configure.js
.
My email credentials that I supplied are correct. I tried using nodemailer 0.7.1
in a simple script to send a message through the Gmail SMTP client in the same way your code is doing so, and it is failing:
var nodemailer = require('nodemailer');
// create reusable transporter object using SMTP transport
var transporter = nodemailer.createTransport({
service: 'Gmail',
auth: {
user: 'gmail.username@gmail.com',
pass: 'userpass'
}
});
// setup e-mail data with unicode symbols
var mailOptions = {
from: 'Jonanthan Whitaker ✔ <gmail.username@gmail.com>', // sender address
to: 'gmail.username@gmail.com', // list of receivers
subject: 'Hello ✔', // Subject line
text: 'Hello world ✔', // plaintext body
html: '<b>Hello world ✔</b>' // html body
};
// send mail with defined transport object
transporter.sendMail(mailOptions, function(error, info){
if(error){
console.log(error);
}else{
console.log('Message sent: ' + info.response);
}
});
With the latest version of nodemailer (1.4.0) it works just fine. However, if 0.7.1 I get the error:
$ node test-nodemailer.js [Error: No transport method defined]
Ok I haven't updated dependencies in a while as I have been working on other projects. Sounds like I need to bump nodemailer to 1.4.0.
Will fix it up at some point today.
On 14 July 2015 at 23:14, Jonathan Whitaker notifications@github.com wrote:
Indeed, I did run node bin/configure.js.
My email credentials that I supplied are correct. I tried using nodemailer 0.7.1 in a simple script to send a message through the Gmail SMTP client in the same way your code is doing so, and it is failing:
var nodemailer = require('nodemailer');
// create reusable transporter object using SMTP transport var transporter = nodemailer.createTransport({ service: 'Gmail', auth: { user: 'gmail.username@gmail.com', pass: 'userpass' } });
// setup e-mail data with unicode symbols var mailOptions = { from: 'Jonanthan Whitaker ✔ gmail.username@gmail.com', // sender address to: 'gmail.username@gmail.com', // list of receivers subject: 'Hello ✔', // Subject line text: 'Hello world ✔', // plaintext body html: 'Hello world ✔' // html body };
// send mail with defined transport object transporter.sendMail(mailOptions, function(error, info){ if(error){ console.log(error); }else{ console.log('Message sent: ' + info.response); } });
With the latest version of nodemailer (1.4.0) it works just fine. However, if 0.7.1 I get the error:
$ node test-nodemailer.js [Error: No transport method defined]
— Reply to this email directly or view it on GitHub https://github.com/smaxwellstewart/hapi-dash/issues/10#issuecomment-121471364 .
Great! Thanks ;)
Bumped now!
On 15 July 2015 at 14:43, Jonathan Whitaker notifications@github.com wrote:
Great! Thanks ;)
— Reply to this email directly or view it on GitHub https://github.com/smaxwellstewart/hapi-dash/issues/10#issuecomment-121709008 .
First off, great work on this project! It's going to allow me to get a configuration dashboard up and running with very little effort. Thanks for all your work.
Problem: I am unable to register new users. I get the message
"Success! An activation email has been sent to you."
, but I do not receive and email.Is there a configuration setting that I am missing?