[openstreetmap/openstreetmap-website] Expose smtp config (#2571)
Kevin Greene
notifications at github.com
Sun Mar 29 02:28:31 UTC 2020
Thank you for the help! I got it to work with the following lines in my Dockerfile:
```bash
echo "
Rails.application.configure do
# Override the default settings loaded in config/initializers/action_mailer.rb.
config.after_initialize do
ActionMailer::Base.delivery_method = :smtp
ActionMailer::Base.smtp_settings = {
:address => 'smtp.mailgun.org',
:port => 587,
:domain => 'mywebsite.com',
:user_name => '${OSM_MAILGUN_USERNAME}',
:password => '${OSM_MAILGUN_PASSWORD}',
:authentication => 'plain',
:enable_starttls_auto => true,
}
end
end" >> "config/environments/production.rb"
```
It feels a bit weird to patch the production.rb file, but I couldn't figure out a better way.
--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/issues/2571#issuecomment-605548657
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20200328/67bae61c/attachment.htm>
More information about the rails-dev
mailing list