diff --git a/.env.example b/.env.example index a361303c3..e399482d6 100644 --- a/.env.example +++ b/.env.example @@ -300,8 +300,8 @@ ############################################################################### # The SMTP server hostname. # Type: string -# Default: localhost -# SMTP_HOST=localhost +# Default: +# SMTP_HOST= ############################################################################### # The SMTP post. diff --git a/app/boot_levels.go b/app/boot_levels.go index 74609cfc9..43a780df3 100644 --- a/app/boot_levels.go +++ b/app/boot_levels.go @@ -806,11 +806,13 @@ func applySmtpOptionsToSettings(ctx context.Context, log *zap.Logger, opt option log.Warn( "Environmental variables (SMTP_*) and SMTP settings " + "(most likely changed via admin console) are not the same. " + - "When server was restarted, values from environmental" + + "When server was restarted, values from environmental " + "variables were copied to settings for easier management. " + "To avoid confusion and potential issues, we suggest you to " + "remove all SMTP_* variables") } + + return } // SMTP server settings do not exist but diff --git a/app/options/SMTP.cue b/app/options/SMTP.cue index c464dcd48..bfb5adabd 100644 --- a/app/options/SMTP.cue +++ b/app/options/SMTP.cue @@ -21,12 +21,10 @@ SMTP: schema.#optionsGroup & { options: { host: { - defaultValue: "localhost" description: "The SMTP server hostname." } port: { type: "int" - defaultGoExpr: "25" description: "The SMTP post." } user: { diff --git a/pkg/options/options.gen.go b/pkg/options/options.gen.go index 2a8353f88..87b741a1e 100644 --- a/pkg/options/options.gen.go +++ b/pkg/options/options.gen.go @@ -430,10 +430,7 @@ func SCIM() (o *SCIMOpt) { // // This function is auto-generated func SMTP() (o *SMTPOpt) { - o = &SMTPOpt{ - Host: "localhost", - Port: 25, - } + o = &SMTPOpt{} // Custom defaults func(o interface{}) {