mirror of
https://github.com/dawidd6/action-send-mail.git
synced 2024-12-26 11:03:06 +07:00
main: ignore cert if desired
This commit is contained in:
parent
9210f61cf4
commit
3082f5221c
4
main.js
4
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({
|
||||
|
Loading…
Reference in New Issue
Block a user