Chore: Moved the email ingress method to an env variable (#777) (#806)

* Chore: Moved the email ingress method to an env variable (#777)
* Moved the email ingress method in config to an environment variable
* Updated documentation to reflect this

* Added ingress config to staging env config (#777)
* Re-arranged the order in env configs so that email related configs are together
This commit is contained in:
Sony Mathew
2020-05-02 23:29:09 +05:30
committed by GitHub
parent 8655466fa5
commit d8131e450c
5 changed files with 46 additions and 26 deletions

View File

@@ -1,9 +1,6 @@
Rails.application.configure do
# Settings specified here will take precedence over those in config/application.rb.
# set this to appropriate ingress channel when you are doing development in local with regards to incoming emails
# config.action_mailbox.ingress = :sendgrid
# In the development environment your application's code is reloaded on
# every request. This slows down response time but is perfect for development
# since you don't have to restart the web server when you make code changes.
@@ -64,6 +61,14 @@ Rails.application.configure do
config.action_mailer.smtp_settings = smtp_settings
# Set this to appropriate ingress service for which the options are :
# :relay for Exim, Postfix, Qmail
# :mailgun for Mailgun
# :mandrill for Mandrill
# :postmark for Postmark
# :sendgrid for Sendgrid
config.action_mailbox.ingress = ENV.fetch('RAILS_INBOUND_EMAIL_SERVICE', 'relay').to_sym
Rails.application.routes.default_url_options = { host: 'localhost', port: 3000 }
# Print deprecation notices to the Rails logger.