title: ActionView::Template::Error: Missing host to link to
body: <p>As the title implies, I'm getting this error when I try to use <code>link_to</code> in my mailer templates:</p>
  
  <pre><code>ActionView::Template::Error: Missing host to link to! Please provide the :host parameter, set default_url_options[:host], or set :only_path to true
  </code></pre>
  
  <p>I tried to follow it's instructions, and I also found <a href="https://stackoverflow.com/questions/4114835/heroku-devise-missing-host-to-link-to-please-provide-host-parameter-or-set-d">this post</a>, but I'm still getting the error.</p>
  
  <p>I've tried adding <code>config.action_mailer.default_url_options = { host: 'example.com' }</code> to each of the following files and none of them worked:</p>
  
  <pre><code>/config/environment.rb
  /config/application.rb (inside the module for my app)
  /config/development.rb (I'm in development mode)
  </code></pre>
  
  <p>Has something changed in Rails 4 that makes this work differently?</p>