fix(mailer): add TLS settings for internal SMTP relay
- rejectUnauthorized: false (relay cert is for mail.keylinkit.net, not 172.17.0.1) - connection/greeting/socket timeouts for reliability Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -17,6 +17,10 @@ if (SMTP_HOST && SMTP_USER && SMTP_PASS) {
|
|||||||
port: SMTP_PORT,
|
port: SMTP_PORT,
|
||||||
secure: SMTP_PORT === 465,
|
secure: SMTP_PORT === 465,
|
||||||
auth: { user: SMTP_USER, pass: SMTP_PASS },
|
auth: { user: SMTP_USER, pass: SMTP_PASS },
|
||||||
|
connectionTimeout: 10_000,
|
||||||
|
greetingTimeout: 10_000,
|
||||||
|
socketTimeout: 15_000,
|
||||||
|
tls: { rejectUnauthorized: false }, // tunnel relay cert is for mail.keylinkit.net, not 172.17.0.1
|
||||||
})
|
})
|
||||||
console.log(`[mailer] SMTP configured: ${SMTP_HOST}:${SMTP_PORT}`)
|
console.log(`[mailer] SMTP configured: ${SMTP_HOST}:${SMTP_PORT}`)
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
Reference in New Issue
Block a user