From 5b401465928a1b07da10a4ba72637adc1b049c15 Mon Sep 17 00:00:00 2001 From: Rene Date: Tue, 16 Sep 2025 21:46:54 +0200 Subject: [PATCH] test --- config/environments/production.rb | 23 ++++++++--------------- 1 file changed, 8 insertions(+), 15 deletions(-) diff --git a/config/environments/production.rb b/config/environments/production.rb index 3cab867..0c7ad4f 100644 --- a/config/environments/production.rb +++ b/config/environments/production.rb @@ -74,7 +74,9 @@ Rails.application.configure do # Use a real queuing backend for Active Job (and separate queues per environment) # config.active_job.queue_adapter = :resque # config.active_job.queue_name_prefix = "wedding_#{Rails.env}" - + config.read_encrypted_secrets = true + config.action_mailer.perform_deliveries = true + config.action_mailer.delivery_method = :smtp config.action_mailer.perform_caching = false # Ignore bad email addresses and do not raise email delivery errors. @@ -85,25 +87,16 @@ Rails.application.configure do host: ENV['CANONICAL_HOST'], protocol: ENV['CANONICAL_HOST_PROTOCOL'] || 'https' } - config.action_mailer.asset_host = ENV['SMTP_DOMAIN'] - config.action_mailer.delivery_method = :smtp config.action_mailer.smtp_settings = { - address: 'smtp.gmail.com', - port: 587, - domain: 'wedding.linepe.de', + address: ENV['SMTP_ADDRESS'], + port: (ENV['SMTP_PORT'] || 587).to_i, + domain: ENV['SMTP_DOMAIN'], user_name: ENV['SMTP_USER_NAME'], password: ENV['SMTP_PASSWORD'], - authentication: 'plain', - enable_starttls_auto: 'true' + authentication: ENV['SMTP_AUTHENTICATION'] || :plain, + enable_starttls_auto: ENV['SMTP_ENABLE_STARTTLS_AUTO'] || 'true' } - config.action_mailer.default_url_options = { host: 'https://wedding.linepe.de' } - config.action_mailer.delivery_method = :letter_opener - config.action_mailer.perform_deliveries = true - # Don't care if the mailer can't send. - config.action_mailer.raise_delivery_errors = false - - config.action_mailer.perform_caching = false # Enable locale fallbacks for I18n (makes lookups for any locale fall back to # the I18n.default_locale when a translation cannot be found).