send email with gmail
This commit is contained in:
@@ -1,13 +1,27 @@
|
||||
'use strict';
|
||||
const nodemailer = require('nodemailer');
|
||||
const FROM = '"Qlik" <no-reply@qlik.com>';
|
||||
const transporter = nodemailer.createTransport({
|
||||
//service: 'gmail',
|
||||
host: 'smtp.qliktech.com',
|
||||
port: 587,
|
||||
secure: false, // true for 465, false for other ports
|
||||
//auth: config.gmailstmpauth
|
||||
});
|
||||
var transporter;
|
||||
|
||||
if ( process.env.GMAIL_USERNAME && process.env.GMAIL_PASSWORD ) {
|
||||
//GMAIL
|
||||
transporter = nodemailer.createTransport({
|
||||
service: 'gmail',
|
||||
port: 587,
|
||||
secure: false,
|
||||
auth: {
|
||||
user: process.env.GMAIL_USERNAME,
|
||||
pass: process.env.GMAIL_PASSWORD
|
||||
}
|
||||
});
|
||||
} else {
|
||||
//QLIK
|
||||
transporter = nodemailer.createTransport({
|
||||
host: 'smtp.qliktech.com',
|
||||
port: 587,
|
||||
secure: false, // true for 465, false for other ports
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
function getHtmlNewProvision(provision, scenario) {
|
||||
|
||||
Reference in New Issue
Block a user