From 11c4713839e57f5be0ace50965c57fb0a1cbcab5 Mon Sep 17 00:00:00 2001 From: f Date: Tue, 27 Apr 2021 11:52:35 -0300 Subject: [PATCH] entorno por defecto --- .env.example | 1 + config/environments/production.rb | 6 +++--- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/.env.example b/.env.example index a664acb7..56075093 100644 --- a/.env.example +++ b/.env.example @@ -1,6 +1,7 @@ RAILS_ENV= IMAP_SERVER= DEFAULT_FROM= +EXCEPTION_TO= SKEL_SUTTY=https://0xacab.org/sutty/skel.sutty.nl # XXX: Si cambiás esta variable, tenés que editar config/webpacker.yml también :( SUTTY=sutty.local diff --git a/config/environments/production.rb b/config/environments/production.rb index b2f91a3d..a51e1a59 100644 --- a/config/environments/production.rb +++ b/config/environments/production.rb @@ -145,14 +145,14 @@ Rails.application.configure do domain: ENV.fetch('SUTTY', 'sutty.nl'), enable_starttls_auto: false } - config.action_mailer.default_options = { from: ENV['DEFAULT_FROM'] } + config.action_mailer.default_options = { from: ENV.fetch('DEFAULT_FROM', "noreply@sutty.nl") } config.middleware.use ExceptionNotification::Rack, error_grouping: true, email: { email_prefix: '', - sender_address: ENV['DEFAULT_FROM'], - exception_recipients: ENV['EXCEPTION_TO'], + sender_address: ENV.fetch('DEFAULT_FROM', "noreply@sutty.nl"), + exception_recipients: ENV.fetch('EXCEPTION_TO', "errors@sutty.nl"), normalize_subject: true }