diff --git a/api/example.env b/api/example.env index 86ca3ffe95..9249c9483c 100644 --- a/api/example.env +++ b/api/example.env @@ -143,6 +143,7 @@ EMAIL_SENDMAIL_PATH="/usr/sbin/sendmail" # EMAIL_SMTP_HOST="localhost" # EMAIL_SMTP_PORT=465 # EMAIL_SMTP_SECURE=false # Use TLS +# EMAIL_SMTP_IGNORE_TLS=false # EMAIL_SMTP_USER="username" # EMAIL_SMTP_PASSWORD="password" diff --git a/api/src/mailer.ts b/api/src/mailer.ts index 9a664e6d08..1b62abb55d 100644 --- a/api/src/mailer.ts +++ b/api/src/mailer.ts @@ -28,6 +28,7 @@ export default function getMailer(): Transporter { host: env.EMAIL_SMTP_HOST, port: env.EMAIL_SMTP_PORT, secure: env.EMAIL_SMTP_SECURE, + ignoreTLS: env.EMAIL_SMTP_IGNORE_TLS, auth: auth, } as Record); } else if (env.EMAIL_TRANSPORT.toLowerCase() === 'mailgun') { diff --git a/docs/reference/environment-variables.md b/docs/reference/environment-variables.md index 03dd8a55bf..2334a1db67 100644 --- a/docs/reference/environment-variables.md +++ b/docs/reference/environment-variables.md @@ -310,14 +310,15 @@ Based on the `EMAIL_TRANSPORT` used, you must also provide the following configu ### SMTP (`smtp`) -| Variable | Description | Default Value | -| --------------------- | ---------------- | ------------- | -| `EMAIL_SMTP_HOST` | SMTP Host | -- | -| `EMAIL_SMTP_PORT` | SMTP Port | -- | -| `EMAIL_SMTP_USER` | SMTP User | -- | -| `EMAIL_SMTP_PASSWORD` | SMTP Password | -- | -| `EMAIL_SMTP_POOL` | Use SMTP pooling | -- | -| `EMAIL_SMTP_SECURE` | Enable TLS | -- | +| Variable | Description | Default Value | +| ----------------------- | ---------------- | ------------- | +| `EMAIL_SMTP_HOST` | SMTP Host | -- | +| `EMAIL_SMTP_PORT` | SMTP Port | -- | +| `EMAIL_SMTP_USER` | SMTP User | -- | +| `EMAIL_SMTP_PASSWORD` | SMTP Password | -- | +| `EMAIL_SMTP_POOL` | Use SMTP pooling | -- | +| `EMAIL_SMTP_SECURE` | Enable TLS | -- | +| `EMAIL_SMTP_IGNORE_TLS` | Ignore TLS | -- | ### Mailgun (`mailgun`)