1

I have three environments and postmark mailing is just working on production. I checked the api keys that I created and nothing. I even tried to use the same api key from production and it doesn't work on staging.

Rails v. 5.0.1

gemfile:

gem 'postmark' (v.1.14.0)

gem 'postmark-rails' (v. 0.18.0)

production.rb

  config.action_mailer.delivery_method = :postmark
  config.action_mailer.postmark_settings = { :api_token => ENV["POSTMARK_API_KEY"] }
  config.action_mailer.default_url_options = { host: "www.mywebsite.com" }

development.rb

  config.action_mailer.delivery_method = :postmark
  config.action_mailer.postmark_settings = { :api_token => ENV["POSTMARK_API_KEY"] }
  config.action_mailer.default_url_options = { host: 'localhost', port: 3000 }

staging.rb

  config.action_mailer.delivery_method = :postmark
  config.action_mailer.postmark_settings = { :api_token => ENV["POSTMARK_API_KEY"] }
  config.action_mailer.default_url_options = { host: "myapp.herokuapp.com" }
Fillype Farias
  • 532
  • 1
  • 5
  • 16

1 Answers1

1

I tried to send email on using the method deliver_now instead of deliver_later and worked. I guess the problem is with redis gem configuration that I have to figure it out.

Fillype Farias
  • 532
  • 1
  • 5
  • 16