Deployment should fail if SMTP isn't configured #4

Open
opened 2023-10-16 13:02:59 +00:00 by knoflook · 2 comments
Owner

Discourse relies heavily on outgoing mail, setting SMTP up shouldn't be optional. my suggestion is to uncomment the lines responsible for smtp config in .env.sample

Discourse relies heavily on outgoing mail, setting SMTP up shouldn't be optional. my suggestion is to uncomment the lines responsible for smtp config in `.env.sample`
Owner

yeah that seems wise, Discourse can be used without email sending, but that's probably an unusual case which should require some kind of DISABLE_EMAIL setting to confirm

yeah that seems wise, Discourse _can_ be used without email sending, but that's probably an unusual case which should require some kind of `DISABLE_EMAIL` setting to confirm
Owner

Yeah, agree. Some random docs from my adventure:

I used the default admin user for myself and had to do https://docs.bitnami.com/aws/apps/discourse/configuration/change-default-email/ to change my email. Enabling SMTP and asking it to send a verficiation mail for a new email address didn't work.

Here is an example mail config for a 3rd party riseup notification setup:

# Outgoing email
DISCOURSE_SMTP_HOST=mail.riseup.net
DISCOURSE_SMTP_PORT=587
DISCOURSE_SMTP_USER=...
DISCOURSE_SMTP_PROTOCOL=tls
DISCOURSE_SMTP_AUTH=plain

# Set this if you send e-mails from a different domain than noreply@$DOMAIN
DISCOURSE_NOTIFICATION_EMAIL=$SMTP_USER

# SMTP authentication
COMPOSE_FILE="compose.yml:compose.smtpauth.yml"
SECRET_SMTP_PASSWORD_VERSION=v1

I think I still had to edit DISCOURSE_NOTIFICATION_EMAIL in the settings? Unsure.

Yeah, agree. Some random docs from my adventure: I used the default admin user for myself and had to do https://docs.bitnami.com/aws/apps/discourse/configuration/change-default-email/ to change my email. Enabling SMTP and asking it to send a verficiation mail for a new email address didn't work. Here is an example mail config for a 3rd party riseup notification setup: ``` # Outgoing email DISCOURSE_SMTP_HOST=mail.riseup.net DISCOURSE_SMTP_PORT=587 DISCOURSE_SMTP_USER=... DISCOURSE_SMTP_PROTOCOL=tls DISCOURSE_SMTP_AUTH=plain # Set this if you send e-mails from a different domain than noreply@$DOMAIN DISCOURSE_NOTIFICATION_EMAIL=$SMTP_USER # SMTP authentication COMPOSE_FILE="compose.yml:compose.smtpauth.yml" SECRET_SMTP_PASSWORD_VERSION=v1 ``` I think I still had to edit `DISCOURSE_NOTIFICATION_EMAIL` in the settings? Unsure.
Sign in to join this conversation.
No Label
No Milestone
No project
No Assignees
3 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: coop-cloud/discourse#4
No description provided.