Recently I have been working on a Rails app hosted on our deployment server (Heroku) and trying to get ActionMailer and Ruby working with Gmail’s SMTP service. The one catch is you need to use the TLS protocol and prior to Ruby 1.8.7 (Rails 2.3+) you need to write your own wrapper.
Heroku (still using 1.8.6 on some servers) had a nifty addon (now just a blog post and a Rails plugin) that has a TLS wrapper and configuration for ActionMailer’s SMTP server settings. Awesome!
But… the plugin still fails to work on a platform with Ruby 1.8.7! Most notably my local development environment. Fortunately the internet is great and solutions can be found.
But… something inside of me still wanted to take advantage of the built in support. So I quickly went ahead and did just that and posted my changes to the Heroku google group (a working alternative to the plugin is mentioned here as well).
Hopefully this helps anyone looking for the same answers as me.
* Update *
Heroku just updated their platform (with a complimentary blog post) to support painless migration to updated deployment stacks (including 1.8.7 and 1.9.1).
Filed under: Rails, Ruby, Technical | Tagged: gmail, Heroku, Rails, Ruby | Leave a Comment »





