tweaks to actionmailer
authorAidan Cornelius-Bell <aidan@cornelius-bell.com>
Sun, 22 Sep 2024 23:17:52 +0000 (08:47 +0930)
committerAidan Cornelius-Bell <aidan@cornelius-bell.com>
Sun, 22 Sep 2024 23:17:52 +0000 (08:47 +0930)
config/environments/production.rb

index 01e9ceae8cbff640a64ef72a2db3911d5a6553a1..56bbb57fa84be2fefaf394cf8107b6ff631ebe0c 100644 (file)
@@ -78,6 +78,15 @@ Rails.application.configure do
   # Set this to true and configure the email server for immediate delivery to raise delivery errors.
   # config.action_mailer.raise_delivery_errors = false
   
+  config.action_mailer.delivery_method = :smtp
+  config.action_mailer.smtp_settings = {
+    address:              ENV['SMTP_ADDRESS'],
+    port:                 ENV['SMTP_PORT'],
+    user_name:            ENV['SMTP_USERNAME'],
+    password:             ENV['SMTP_PASSWORD'],
+    authentication:       'plain',
+    enable_starttls:      true
+  }
   config.action_mailer.default_options = {
     from: "mind reader <mr@acb.boo>"
   }