title: Devise Confirmable continues to send to localhost:3000 in production mode
body: <p>I've successfully set up Devise Confirmable with Facebook authentication, and everything works perfectly in development mode. When I push to heroku and run in production mode, the app send an email but the link routes me to:</p>
  
  <pre><code>http://localhost:3000/users/confirmation?confirmation_token=E2jH_ehmHwqy2zyvJGcs
  </code></pre>
  
  <p>If I replace localhost:3000 with my app name everything works.</p>
  
  <p>In my config/environments/production.rb file I have the following code:</p>
  
  <pre><code>config.action_mailer.raise_delivery_errors = true
  config.action_mailer.delivery_method = :smtp
  config.action_mailer.perform_deliveries = true 
  
  config.action_mailer.smtp_settings = {
    :address =&gt; "smtp.gmail.com",
    :port =&gt; 587,
    :domain =&gt; "gmail.com",
    :user_name =&gt; ENV["GMAIL_USERNAME"],
    :password =&gt; ENV["GMAIL_PASSWORD"],
    :authentication =&gt; :plain,
    :enable_starttls_auto =&gt; true 
  }
  config.action_mailer.default_url_options = { :host =&gt; 'http://myapp.herokuapp.com' }
  </code></pre>
  
  <p>And in my development I have:</p>
  
  <pre><code>config.action_mailer.raise_delivery_errors = true
  
  config.action_mailer.delivery_method = :smtp
  config.action_mailer.perform_deliveries = true 
  config.action_mailer.default_url_options = { :host =&gt; 'http://localhost:3000' }
  config.action_mailer.smtp_settings = {
    :address =&gt; "smtp.gmail.com",
    :port =&gt; 587,
    :domain =&gt; "gmail.com",
    :user_name =&gt; ENV["GMAIL_USERNAME"],
    :password =&gt; ENV["GMAIL_PASSWORD"],
    :authentication =&gt; :plain,
    :enable_starttls_auto =&gt; true 
  }
  </code></pre>
  
  <p>Any thoughts on what to do? I couldn't find a straight answer anywhere. </p>
  
  <p>I'm using rails 4 &amp; Devise 3.2.4</p>