How do I configure the hostname for Rails ActionMailer?

前端 未结 7 1244
日久生厌
日久生厌 2020-12-29 06:05

I\'m working on a fairly traditional forgot password email - I want to email the user a password change token embedded in a link that they can click on in order to change th

7条回答
  •  隐瞒了意图╮
    2020-12-29 06:28

    You probably want to set :protocol => 'https' as well, btw.

    config.action_mailer.default_url_options = { 
        :host => "portal.example.com", 
        :protocol => 'https' 
    }
    

提交回复
热议问题