diff --git a/config.yml.sample b/config.yml.sample index 0df19d8f..e38e5383 100644 --- a/config.yml.sample +++ b/config.yml.sample @@ -129,6 +129,8 @@ mailer: host: "" # SMTP Host port port: 587 + # SMTP Auth Type. Can be either `plain`, `login` or `cram-md5`. + authtype: "plain" # SMTP username username: "user" # SMTP password diff --git a/docs/content/doc/setup/config.md b/docs/content/doc/setup/config.md index 5a903537..931fab19 100644 --- a/docs/content/doc/setup/config.md +++ b/docs/content/doc/setup/config.md @@ -665,6 +665,17 @@ Full path: `mailer.port` Environment path: `VIKUNJA_MAILER_PORT` +### authtype + +SMTP Auth Type. Can be either `plain`, `login` or `cram-md5`. + +Default: `plain` + +Full path: `mailer.authtype` + +Environment path: `VIKUNJA_MAILER_AUTHTYPE` + + ### username SMTP username diff --git a/pkg/mail/send_mail.go b/pkg/mail/send_mail.go index a693e798..ac4ea1c4 100644 --- a/pkg/mail/send_mail.go +++ b/pkg/mail/send_mail.go @@ -17,10 +17,11 @@ package mail import ( + "io" + "code.vikunja.io/api/pkg/config" "code.vikunja.io/api/pkg/log" "code.vikunja.io/api/pkg/version" - "io" "github.com/wneessen/go-mail" )