From 3082f5221cd063a72a3176197f441720def42b78 Mon Sep 17 00:00:00 2001 From: Dawid Dziurla Date: Fri, 26 Mar 2021 08:42:12 +0100 Subject: [PATCH] main: ignore cert if desired --- main.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/main.js b/main.js index feadfce5..d36b8077 100644 --- a/main.js +++ b/main.js @@ -44,6 +44,7 @@ async function main() { const contentType = core.getInput("content_type", { required: true }) const attachments = core.getInput("attachments", { required: false }) const convertMarkdown = core.getInput("convert_markdown", { required: false }) + const ignoreCert = core.getInput("ignore_cert", { required: false }) const transport = nodemailer.createTransport({ host: serverAddress, @@ -53,6 +54,9 @@ async function main() { user: username, pass: password, } + tls: ignoreCert ? { + rejectUnauthorized: false + } : undefined }) const info = await transport.sendMail({