]> source.dussan.org Git - gitea.git/commitdiff
Update email-setup.en-us.md (#26068) (#26166)
authorGiteabot <teabot@gitea.io>
Wed, 26 Jul 2023 15:55:27 +0000 (23:55 +0800)
committerGitHub <noreply@github.com>
Wed, 26 Jul 2023 15:55:27 +0000 (10:55 -0500)
Backport #26068 by @felixvictor

The setting `MAILER_TYPE` is deprecated.
According to the config cheat sheet, it should be `PROTOCOL`.

Co-authored-by: Felix Victor <felix.victor.na@gmail.com>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
docs/content/administration/email-setup.en-us.md
docs/content/administration/email-setup.zh-cn.md
docs/content/installation/with-docker-rootless.en-us.md
docs/content/installation/with-docker-rootless.zh-cn.md
docs/content/installation/with-docker.en-us.md
docs/content/installation/with-docker.zh-cn.md
tests/mssql.ini.tmpl
tests/mysql.ini.tmpl
tests/pgsql.ini.tmpl
tests/sqlite.ini.tmpl

index 2f92e20410dec1bc69c14d77ec9c5ca0263da080..10058d82849baed719e0f4f8eba11a2e72bf278f 100644 (file)
@@ -31,7 +31,7 @@ Note: For Internet-facing sites consult documentation of your MTA for instructio
 [mailer]
 ENABLED       = true
 FROM          = gitea@mydomain.com
-MAILER_TYPE   = sendmail
+PROTOCOL      = sendmail
 SENDMAIL_PATH = /usr/sbin/sendmail
 SENDMAIL_ARGS = "--" ; most "sendmail" programs take options, "--" will prevent an email address being interpreted as an option.
 ```
@@ -44,10 +44,9 @@ Directly use SMTP server as relay. This option is useful if you don't want to se
 [mailer]
 ENABLED        = true
 FROM           = gitea@mydomain.com
-MAILER_TYPE    = smtp
+PROTOCOL       = smtps
 SMTP_ADDR      = mail.mydomain.com
 SMTP_PORT      = 587
-IS_TLS_ENABLED = true
 USER           = gitea@mydomain.com
 PASSWD         = `password`
 ```
@@ -80,7 +79,7 @@ SMTP_PORT      = 465
 FROM           = example.user@gmail.com
 USER           = example.user
 PASSWD         = `***`
-MAILER_TYPE    = smtp
+PROTOCOL       = smtp
 IS_TLS_ENABLED = true
 ```
 
index e526a9d4337c512386cac022222cd07a39ce144f..0a7ac3378f98d5e8a35b78fec7b1db4a03139563 100644 (file)
@@ -31,7 +31,7 @@ Gitea 具有邮件功能,用于发送事务性邮件(例如注册确认邮
 [mailer]
 ENABLED       = true
 FROM          = gitea@mydomain.com
-MAILER_TYPE   = sendmail
+PROTOCOL   = sendmail
 SENDMAIL_PATH = /usr/sbin/sendmail
 SENDMAIL_ARGS = "--" ; 大多数 "sendmail" 程序都接受选项,使用 "--" 将防止电子邮件地址被解释为选项。
 ```
@@ -44,10 +44,9 @@ SENDMAIL_ARGS = "--" ; 大多数 "sendmail" 程序都接受选项,使用 "--"
 [mailer]
 ENABLED        = true
 FROM           = gitea@mydomain.com
-MAILER_TYPE    = smtp
+PROTOCOL    = smtps
 SMTP_ADDR      = mail.mydomain.com
 SMTP_PORT      = 587
-IS_TLS_ENABLED = true
 USER           = gitea@mydomain.com
 PASSWD         = `password`
 ```
@@ -80,8 +79,7 @@ SMTP_PORT      = 465
 FROM           = example.user@gmail.com
 USER           = example.user
 PASSWD         = `***`
-MAILER_TYPE    = smtp
-IS_TLS_ENABLED = true
+PROTOCOL    = smtps
 ```
 
 请注意,您需要创建并使用一个 [应用密码](https://support.google.com/accounts/answer/185833?hl=en) 并在您的 Google 帐户上启用 2FA。您将无法直接使用您的 Google 帐户密码。
index 3c81c8633c9cd9693e38511fc3967d4c36e5a328..fc99819d7f7c340c41f785ee40ec57004815cba5 100644 (file)
@@ -306,7 +306,7 @@ services:
     environment:
       - GITEA__mailer__ENABLED=true
       - GITEA__mailer__FROM=${GITEA__mailer__FROM:?GITEA__mailer__FROM not set}
-      - GITEA__mailer__MAILER_TYPE=smtp
+      - GITEA__mailer__PROTOCOL=smtp
       - GITEA__mailer__HOST=${GITEA__mailer__HOST:?GITEA__mailer__HOST not set}
       - GITEA__mailer__IS_TLS_ENABLED=true
       - GITEA__mailer__USER=${GITEA__mailer__USER:-apikey}
index 1910e0a884000d5762b7df0e66744f87bbf4738b..9d5013eaa091892508028611fc06a6b96dbcddb2 100644 (file)
@@ -274,7 +274,7 @@ services:
     environment:
       - GITEA__mailer__ENABLED=true
       - GITEA__mailer__FROM=${GITEA__mailer__FROM:?GITEA__mailer__FROM not set}
-      - GITEA__mailer__MAILER_TYPE=smtp
+      - GITEA__mailer__PROTOCOL=smtp
       - GITEA__mailer__HOST=${GITEA__mailer__HOST:?GITEA__mailer__HOST not set}
       - GITEA__mailer__IS_TLS_ENABLED=true
       - GITEA__mailer__USER=${GITEA__mailer__USER:-apikey}
index 7b47046031d6ecc15d6671c63fc1740c34ee1636..f5a09e9fc5245704b674f243bb9d524196452256 100644 (file)
@@ -303,9 +303,8 @@ services:
     environment:
       - GITEA__mailer__ENABLED=true
       - GITEA__mailer__FROM=${GITEA__mailer__FROM:?GITEA__mailer__FROM not set}
-      - GITEA__mailer__MAILER_TYPE=smtp
+      - GITEA__mailer__PROTOCOL=smtps
       - GITEA__mailer__HOST=${GITEA__mailer__HOST:?GITEA__mailer__HOST not set}
-      - GITEA__mailer__IS_TLS_ENABLED=true
       - GITEA__mailer__USER=${GITEA__mailer__USER:-apikey}
       - GITEA__mailer__PASSWD="""${GITEA__mailer__PASSWD:?GITEA__mailer__PASSWD not set}"""
 ```
index e04d3158a1c1cd1df7d6a0f5a198397037edbae9..d8cbc2f9509f017bac3feb6728105e12df271426 100644 (file)
@@ -287,9 +287,8 @@ services:
     environment:
       - GITEA__mailer__ENABLED=true
       - GITEA__mailer__FROM=${GITEA__mailer__FROM:?GITEA__mailer__FROM not set}
-      - GITEA__mailer__MAILER_TYPE=smtp
+      - GITEA__mailer__PROTOCOL=smtps
       - GITEA__mailer__HOST=${GITEA__mailer__HOST:?GITEA__mailer__HOST not set}
-      - GITEA__mailer__IS_TLS_ENABLED=true
       - GITEA__mailer__USER=${GITEA__mailer__USER:-apikey}
       - GITEA__mailer__PASSWD="""${GITEA__mailer__PASSWD:?GITEA__mailer__PASSWD not set}"""
 ```
index 10e70d35fc8177dff62c87dc804dcfbbbd378f43..93ade74805b12df97bd578f6db788e7081e901b8 100644 (file)
@@ -58,7 +58,7 @@ PATH = tests/{{TEST_TYPE}}/gitea-{{TEST_TYPE}}-mssql/data/attachments
 
 [mailer]
 ENABLED = true
-MAILER_TYPE = dummy
+PROTOCOL = dummy
 FROM = mssql-{{TEST_TYPE}}-test@gitea.io
 
 [service]
index 9d6bbd65e6e88c8f65909a3d9378816be37d0828..10aa3cabbee8c5dd59386d2585e25b98d0a960cd 100644 (file)
@@ -58,7 +58,7 @@ SSH_TRUSTED_USER_CA_KEYS = ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQCb4DC1dMFnJ6pXW
 
 [mailer]
 ENABLED = true
-MAILER_TYPE = dummy
+PROTOCOL = dummy
 FROM = mysql-{{TEST_TYPE}}-test@gitea.io
 
 [service]
index dd45ab717aae61696522ab4835764f3e90422818..2b54843c30a6389a08a7068649821e1433d55840 100644 (file)
@@ -59,7 +59,7 @@ PATH = tests/{{TEST_TYPE}}/gitea-{{TEST_TYPE}}-pgsql/data/attachments
 
 [mailer]
 ENABLED = true
-MAILER_TYPE = dummy
+PROTOCOL = dummy
 FROM = pgsql-{{TEST_TYPE}}-test@gitea.io
 
 [service]
index 969c15698daa97d6fc871485e4760e17a8d55f7a..546b27c5f66de14a01857025e4779b98e4e4dfb5 100644 (file)
@@ -55,7 +55,7 @@ PATH = tests/{{TEST_TYPE}}/gitea-{{TEST_TYPE}}-sqlite/data/attachments
 
 [mailer]
 ENABLED     = true
-MAILER_TYPE = dummy
+PROTOCOL = dummy
 FROM        = sqlite-{{TEST_TYPE}}-test@gitea.io
 
 [service]