From c17cc398809764b3fbcf12f7e979eabfffb10970 Mon Sep 17 00:00:00 2001 From: mix irving Date: Wed, 4 Mar 2015 11:27:37 +1300 Subject: [PATCH] extract email settings into ENV :scissors: fixes #405 --- config/environments/development.rb | 9 +++++---- config/environments/production.rb | 9 +++++---- 2 files changed, 10 insertions(+), 8 deletions(-) diff --git a/config/environments/development.rb b/config/environments/development.rb index 50a7f79f..74431de7 100644 --- a/config/environments/development.rb +++ b/config/environments/development.rb @@ -25,10 +25,11 @@ Metamaps::Application.configure do config.action_mailer.delivery_method = :smtp config.action_mailer.smtp_settings = { - address: 'mail.metamaps.cc', - port: 587, - user_name: 'team@metamaps.cc', - password: 'RcxX+s:fht49UX', + address: ENV['SMTP_SERVER'], + port: ENV['SMTP_PORT'], + user_name: ENV['SMTP_USERNAME'], + password: ENV['SMTP_PASSWORD'], + #domain: ENV['SMTP_DOMAIN'] authentication: 'plain', enable_starttls_auto: true, openssl_verify_mode: 'none' } diff --git a/config/environments/production.rb b/config/environments/production.rb index eddb8e01..2186327f 100644 --- a/config/environments/production.rb +++ b/config/environments/production.rb @@ -27,10 +27,11 @@ Metamaps::Application.configure do config.action_mailer.delivery_method = :smtp config.action_mailer.smtp_settings = { - address: 'mail.metamaps.cc', - port: 587, - user_name: 'team@metamaps.cc', - password: 'RcxX+s:fht49UX', + address: ENV['SMTP_SERVER'], + port: ENV['SMTP_PORT'], + user_name: ENV['SMTP_USERNAME'], + password: ENV['SMTP_PASSWORD'], + #domain: ENV['SMTP_DOMAIN'] authentication: 'plain', enable_starttls_auto: true, openssl_verify_mode: 'none' }