Add a comment in docs and config for recommended email port values

Signed-off-by: Thomas Citharel <tcit@tcit.fr>
This commit is contained in:
Thomas Citharel 2020-10-21 10:10:44 +02:00
parent 3cdad293ea
commit e80aece1dd
No known key found for this signature in database
GPG Key ID: A061B9DDE0CA0773
2 changed files with 3 additions and 3 deletions

View File

@ -92,6 +92,7 @@ config :mobilizon, Mobilizon.Web.Email.Mailer,
adapter: Bamboo.SMTPAdapter,
server: "localhost",
hostname: "localhost",
# usually 25, 465 or 587
port: 25,
# or {:system, "SMTP_USERNAME"}
username: nil,
@ -102,7 +103,6 @@ config :mobilizon, Mobilizon.Web.Email.Mailer,
# or {":system", ALLOWED_TLS_VERSIONS"} w/ comma seprated values (e.g. "tlsv1.1,tlsv1.2")
allowed_tls_versions: [:tlsv1, :"tlsv1.1", :"tlsv1.2"],
# can be `true`
ssl: false,
retries: 1,
# can be `true`
no_mx_lookups: false

View File

@ -5,19 +5,19 @@ Mobilizon requires a SMTP server to deliver emails. Using 3rd-party mail provide
## SMTP configuration
Mobilizon default settings assumes a SMTP server listens on `localhost`, port `25`. To specify a specific server and credentials, you can add the following section in your `prod.secret.exs` file and modify credentials to your needs.
```elixir
config :mobilizon, Mobilizon.Web.Email.Mailer,
adapter: Bamboo.SMTPAdapter,
server: "localhost",
hostname: "localhost",
# usually 25, 465 or 587
port: 25,
username: nil,
password: nil,
# can be `:always` or `:never`
tls: :if_available,
allowed_tls_versions: [:tlsv1, :"tlsv1.1", :"tlsv1.2"],
# can be `true`
ssl: false,
retries: 1,
# can be `true`
no_mx_lookups: false,