Я пытаюсь отправить электронную почту через nodemailer без транспорта SMTP. Поэтому я сделал это:
var mail = require("nodemailer").mail;
mail({
from: "Fred Foo ✔ <[email protected]>", // sender address
to: "******@gmail.com", // list of receivers
subject: "Hello ✔", // Subject line
text: "Hello world ✔", // plaintext body
html: "<b>Hello world ✔</b>" // html body
});
Но когда я бегу, я получаю это:
> node sendmail.js
Queued message #1 from [email protected], to [email protected]
Retrieved message #1 from the queue, reolving gmail.com
gmail.com resolved to gmail-smtp-in.l.google.com for #1
Connecting to gmail-smtp-in.l.google.com:25 for message #1
Failed processing message #1
Message #1 requeued for 15 minutes
Closing connection to the server
Error: read ECONNRESET
at errnoException (net.js:901:11)
at TCP.onread (net.js:556:19)
Я на windows 7 32.
ИЗМЕНИТЬ Это похоже на ошибку, связанную с Windows, поскольку она работала над linux
РЕДАКТИРОВАТЬ № 2
В оболочке git, если я введу telnet smtp.gmail 587
, он заблокирован здесь:
220 mx.google.com ESMTP f7...y.24 -gsmtp