Be able to use SMTP transport without TLS (#401)

This commit is contained in:
Anton Shepilov
2024-03-01 16:10:49 +01:00
committed by GitHub
parent ac30657aea
commit 6041212253
5 changed files with 22 additions and 0 deletions
@@ -47,7 +47,10 @@ export default class EmailPusherClass
host: this.configuration.get<string>("smtp_host", ""),
port: this.configuration.get<number>("smtp_port", 25),
secure: false,
ignoreTLS: !this.configuration.get<boolean>("smtp_tls", false),
requireTLS: this.configuration.get<boolean>("smtp_tls", true),
};
this.logger.info(`Start SMTP client with configuration: ${JSON.stringify(smtpConfig)}`);
this.transporter = nodemailer.createTransport(smtpConfig);
this.sender = this.configuration.get<string>("sender", "");
} else {
@@ -53,6 +53,7 @@ export type SMTPClientConfigType = {
port: number;
secure?: boolean;
requireTLS?: boolean;
ignoreTLS?: boolean;
auth?: {
user: string;
pass: string;