-
-
Save datt/5590463 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #Getting email unscrewed | |
| #First configure Devise email in config/initializers/devise.rb: | |
| config.mailer_sender = "[email protected]" | |
| #If you continue to get an error message, did you reboot the server? | |
| #Localhost email testing | |
| #Do this in the shell you’re using to run the Rails server: | |
| #$ export [email protected] | |
| #$ export GMAIL_SMTP_PASSWORD=yourpassword | |
| #Add the following to config/environments/development.rb: | |
| config.action_mailer.default_url_options = { :host => 'localhost:3000' } | |
| config.action_mailer.delivery_method = :smtp | |
| config.action_mailer.perform_deliveries = true | |
| config.action_mailer.raise_delivery_errors = true | |
| config.action_mailer.default :charset => "utf-8" | |
| ActionMailer::Base.smtp_settings = { | |
| :address => "smtp.gmail.com", | |
| :port => 587, | |
| :authentication => :plain, | |
| :domain => ENV['GMAIL_SMTP_USER'], | |
| :user_name => ENV['GMAIL_SMTP_USER'], | |
| :password => ENV['GMAIL_SMTP_PASSWORD'], | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment