feat(scripts): add send-email script using nodemailer
Add a sandboxed send-email.js workflow script with SMTP settings exposed via script config and password loaded from named secrets. Allow nodemailer in the script sandbox require whitelist. Co-authored-by: Nasyarobby Putra <nasyarobby@gmail.com>
This commit is contained in:
@@ -12,7 +12,13 @@ import { getSecretPlaintext } from "./secrets-store.js";
|
||||
|
||||
const hostRequire = createRequire(import.meta.url);
|
||||
|
||||
const ALLOWED_MODULES = new Set(["axios", "jsonata", "node-html-parser", "rss-parser"]);
|
||||
const ALLOWED_MODULES = new Set([
|
||||
"axios",
|
||||
"jsonata",
|
||||
"node-html-parser",
|
||||
"nodemailer",
|
||||
"rss-parser",
|
||||
]);
|
||||
|
||||
const BUILTIN_NAMES = [
|
||||
"Infinity",
|
||||
|
||||
Reference in New Issue
Block a user