Add SMTP security mode selector with SSL/STARTTLS/none options and automatic port switching
Replaced boolean `smtp_use_tls` with explicit `smtp_security` enum field supporting "none", "starttls", and "ssl" modes. Added database migration to create `smtp_security` column with "starttls" default. Updated mailer to use SMTP_SSL client for direct SSL connections on port 465 and SMTP with STARTTLS for port 587. Modified admin settings UI to show dropdown selector with encryption options and auto-adjust
This commit is contained in:
@@ -52,6 +52,7 @@ class AppSettings(Base):
|
||||
smtp_from_email: Mapped[str] = mapped_column(String, default="")
|
||||
smtp_from_name: Mapped[str] = mapped_column(String, default="Cluedo HP")
|
||||
smtp_use_tls: Mapped[bool] = mapped_column(Boolean, default=True)
|
||||
smtp_security: Mapped[str] = mapped_column(String, default="starttls")
|
||||
app_base_url: Mapped[str] = mapped_column(String, default="http://localhost:8081")
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user