feat: support other smtp protocols #39

Merged
fauno merged 2 commits from smtp into master 2025-01-07 20:12:17 +00:00
4 changed files with 4 additions and 2 deletions

View File

@ -54,6 +54,7 @@ SECRET_SECRET_KEY_VERSION=v1 # length=64
# GITEA_MAILER_ADDR=mail.gandi.net
# GITEA_MAILER_PORT=465
# SECRET_SMTP_PASSWORD_VERSION=v1
# GITEA_MAILER_PROTOCOL=smtps
# OATH2 Options
# GITEA_REGISTER_EMAIL_CONFIRM=replace-me

View File

@ -1,4 +1,4 @@
export APP_INI_VERSION=v19
export APP_INI_VERSION=v20
export DOCKER_SETUP_SH_VERSION=v1
export PG_BACKUP_VERSION=v1

View File

@ -71,7 +71,7 @@ JWT_SECRET = {{ secret "jwt_secret" }}
[mailer]
ENABLED = true
FROM = {{ env "GITEA_MAILER_FROM" }}
PROTOCOL = smtps
PROTOCOL = {{ env "GITEA_MAILER_PROTOCOL" }}
decentral1se marked this conversation as resolved
Review

This will break new deploys if they don't update their .env. We can either figure out a way to make backwards compatible (toolshed/organising#359) or add a warning in the release notes? I guess that would be a breaking change tho 🤔

This will break new deploys if they don't update their `.env`. We can either figure out a way to make backwards compatible (https://git.coopcloud.tech/toolshed/organising/issues/359) or add a warning in the release notes? I guess that would be a breaking change tho 🤔
SMTP_ADDR = {{ env "GITEA_MAILER_ADDR" }}
SMTP_PORT = {{ env "GITEA_MAILER_PORT" }}
USER = {{ env "GITEA_MAILER_USER" }}

View File

@ -8,6 +8,7 @@ services:
- GITEA_MAILER_ADDR
- GITEA_MAILER_PORT
- GITEA_MAILER_USER
- "GITEA_MAILER_PROTOCOL=${GITEA_MAILER_FROM:-smtps}"
decentral1se marked this conversation as resolved Outdated
Outdated
Review

@decentral1se what about changing this to:

- GITEA_MAILER_PROTOCOL=${GITEA_MAILER_PROTOCOL:-smtps}
@decentral1se what about changing this to: ```yaml - GITEA_MAILER_PROTOCOL=${GITEA_MAILER_PROTOCOL:-smtps} ```

Nice!

Nice!
secrets:
- smtp_password