about summary refs log tree commit diff
path: root/config/environments
diff options
context:
space:
mode:
authorClaire <claire.github-309c@sitedethib.com>2022-01-16 18:11:20 +0100
committerClaire <claire.github-309c@sitedethib.com>2022-01-16 18:11:20 +0100
commitb61c3ddff8338432fdc287f6bebbf76a12859c17 (patch)
tree702e67a92f3a6e84feed3c06126b14a7e4ecab35 /config/environments
parent07cb948f39464b11959fc506b673a90d9524e519 (diff)
parent462bc65112276f4cbfbeb1efd8cd452fda7d0f23 (diff)
Merge branch 'main' into glitch-soc/merge-upstream
Conflicts:
- `README.md`:
  Upstream added some text, but our README is completely different.
  Kept our README unchanged.
Diffstat (limited to 'config/environments')
-rw-r--r--config/environments/production.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/config/environments/production.rb b/config/environments/production.rb
index 417d53a8f..b72d1b342 100644
--- a/config/environments/production.rb
+++ b/config/environments/production.rb
@@ -107,9 +107,9 @@ Rails.application.configure do
     :authentication       => ENV['SMTP_AUTH_METHOD'] == 'none' ? nil : ENV['SMTP_AUTH_METHOD'] || :plain,
     :ca_file              => ENV['SMTP_CA_FILE'].presence || '/etc/ssl/certs/ca-certificates.crt',
     :openssl_verify_mode  => ENV['SMTP_OPENSSL_VERIFY_MODE'],
-    :enable_starttls_auto => ENV['SMTP_ENABLE_STARTTLS_AUTO'] || true,
-    :tls                  => ENV['SMTP_TLS'].presence,
-    :ssl                  => ENV['SMTP_SSL'].presence,
+    :enable_starttls_auto => ENV['SMTP_ENABLE_STARTTLS_AUTO'] != 'false',
+    :tls                  => ENV['SMTP_TLS'].presence && ENV['SMTP_TLS'] == 'true',
+    :ssl                  => ENV['SMTP_SSL'].presence && ENV['SMTP_SSL'] == 'true',
   }
 
   config.action_mailer.delivery_method = ENV.fetch('SMTP_DELIVERY_METHOD', 'smtp').to_sym