Outgoing e-mail
Eurion sends e-mail through an SMTP server that you specify. It can be your own mail server, a relay service or an e-mail service within the EU.
What is sent
| Sent by | |
|---|---|
| Welcome message when an account is created | identity-service |
| Calendar invitations | identity-service |
| Notifications | notification-service |
| Alerts from the monitoring | Alertmanager, see Monitoring |
Without SMTP settings no e-mail is sent at all, and you get no alerts.
Settings
In the configuration file:
smtp:
host: "smtp.example.se"
port: 587
user: "eurion@example.se"
password: "…"
from: "Eurion <no-reply@example.se>"| Key | Comment |
|---|---|
host | Empty means no e-mail is sent. |
port | 587 with STARTTLS is the default. |
secure | Set true for port 465 (TLS straight away). Not in the template. |
user, password | Sign-in to the SMTP server. The password is stored in secrets.yml. |
from | The sender address. |
Always fill in from
If you leave from empty, e-mail is sent without a sender, and most SMTP servers reject it. Use an address in a domain that the SMTP server is allowed to send for.
SPF and DKIM
Make sure the sender domain has SPF (and preferably DKIM) that allows your SMTP server. Otherwise the e-mail easily ends up in the spam folder.
Already installed? Add the settings to /opt/eurion/deploy/generated/eurion-config.yml and run the kit again as described in Changing the configuration after installation.
Test
First check that the server can reach the SMTP server and that it answers with STARTTLS:
openssl s_client -starttls smtp -connect smtp.example.se:587 -quiet </dev/nullYou should see a greeting starting with 220 and the certificate's details. Then do something that sends e-mail, for example a calendar meeting where you invite another e-mail address that you can read. If no e-mail arrives, look in the logs:
sudo eurion-ctl logs identity-service --no-follow -n 200 | grep -i -E 'smtp|mail'
sudo eurion-ctl logs notification-service --no-follow -n 200 | grep -i -E 'smtp|mail'Common causes: the port is blocked outbound, wrong user name or password, secure does not match the port, or the sender address is not allowed.
Integrated mail server
The kit also has an optional integrated mail server (features.mail). It is not covered by this documentation. Contact support before you switch it on.