我在我的vps中创建了一个带有镜像cms的official docker compose file的镜像实例。
我将其修改为使用邮件枪SMTP帐户,如下所示
version: '3.1'
services:
mariadb:
image: 'docker.io/bitnami/mariadb:10.3-debian-10'
environment:
- ALLOW_EMPTY_PASSWORD=yes
- MARIADB_USER=bn_ghost
- MARIADB_DATABASE=bitnami_ghost
volumes:
- 'mariadb_data:/bitnami'
ghost:
image: 'ghost:3-alpine'
environment:
MARIADB_HOST: mariadb
MARIADB_PORT_NUMBER: 3306
GHOST_DATABASE_USER: bn_ghost
GHOST_DATABASE_NAME: bitnami_ghost
GHOST_HOST: localhost
mail__transport: SMTP
mail__options__service: Mailgun
mail__auth__user: ${MY_MAIL_USER}
mail__auth__pass: ${MY_MAIL_PASS}
mail__from: ${MY_FROM_ADDRESS}
ports:
- '80:2368'
volumes:
- 'ghost_data:/bitnami'
depends_on:
- mariadb
volumes:
mariadb_data:
driver: local
ghost_data:
driver: local但是,当我尝试邀请作者访问该站点时,会出现以下错误
Failed to send 1 invitation: dulara@thinksmart.lk. Please check your email configuration, see https://ghost.org/docs/concepts/config/#mail for instructions我确信我的SMTP凭据是正确的。
我登录到ghost containers bash shell,并在那里检查了它的文件。它的邮件部分是空的

我还是找不到我的错误所在。我不确定变量的名称。但我是从官方文件中拿来的。
发布于 2021-02-12 04:38:33
我举个例子:
url=https://www.exemple.com/
# admin__url=XXX // Remove it (For my side, the redirection is failed)
database__client=mysql
database__connection__host=...
database__connection__port=3306
database__connection__database=ghost
database__connection__user=ghost
database__connection__password=XXX
privacy__useRpcPing=false
mail__transport=SMTP
mail__options__host=smtp.exemple.com
mail__options__port=587
# mail__options__service=Exemple // Remove it
mail__options__auth__user=sys@exemple.com
mail__options__auth__pass=XXX
# mail__options__secureConnection=true // Remove it
mail__from=Exemple Corp. <sys@exemple.com>在您的案例中,更改:
mail__auth__user => mail__options__auth__user
mail__auth__pass => mail__options__auth__pass
和删除:mail__options__service (https://github.com/metabase/metabase/issues/4272#issuecomment-566928334)
https://stackoverflow.com/questions/64845020
复制相似问题