I cannot get postmark to handle registration and forgot password emails:
user_mailer.rb
class UserMailer < ActionMailer::Base
include Devise::Mailers::Helpers
default from: "donotreply@barnpix.com"
def confirmation_instructions(record)
devise_mail(record, :confirmation_instructions)
end
def reset_password_instructions(record)
devise_mail(record, :reset_password_instructions)
end
def unlock_instructions(record)
devise_mail(record, :unlock_instructions)
end
# you can then put any of your own methods here
end
application.rb
config.action_mailer.delivery_method = :postmark
config.action_mailer.postmark_settings = { :api_key => ENV['9302106a-63xxxx-xxx-xx-'] }
user.rb
devise :database_authenticatable, :registerable, :recoverable,
:rememberable, :trackable, :validatable
devise.rb
config.mailer = "UserMailer" # UserMailer is my mailer class
I cannot get this to work at all. Any hints as to what I might be doing wrong or what I might be missing to get this to work ?