trying to get a rails app to work with Gmail under ruby 1.8.6, but
getting some weird errors, any help really appreciated.
Basically I installed the openrain-tls gem from here:
then added my settings to : smtp_gmail.rb
require “smtp_tls”
ActionMailer::Base.raise_delivery_errors = true
ActionMailer::Base.delivery_method = :smtp
ActionMailer::Base.smtp_settings = {
:enable_starttls_auto => true,
:address => “smtp.gmail.com”,
:port => 587,
:domain => ‘mydomain.com’,
:authentication => :plain,
:user_name => ‘[email protected]’,
:password => ‘password’
}
tried it out in script/console and got:
Loading development environment (Rails 2.3.2)
Notifier.deliver_hello_world
ArgumentError: wrong number of arguments (3 for 2)
from
/Users/johngriffiths/Repos/bitbucket/dates/vendor/plugins/action_mailer_optional_tls/lib/smtp_tls.rb:33:in
check_auth_args' from /Users/johngriffiths/Repos/bitbucket/dates/vendor/plugins/action_mailer_optional_tls/lib/smtp_tls.rb:33:in
do_tls_start’
from
/Users/johngriffiths/Repos/bitbucket/dates/vendor/plugins/action_mailer_optional_tls/lib/smtp_tls.rb:18:in
send' from /Users/johngriffiths/Repos/bitbucket/dates/vendor/plugins/action_mailer_optional_tls/lib/smtp_tls.rb:18:in
start’
from
/Users/johngriffiths/Repos/bitbucket/dates/vendor/plugins/action_mailer_optional_tls/lib/smtp_tls.rb:10:in
start' from /Users/johngriffiths/Repos/bitbucket/dates/vendor/plugins/action_mailer_optional_tls/lib/action_mailer_tls.rb:9:in
perform_delivery_smtp’
from
/Library/Ruby/Gems/1.8/gems/actionmailer-2.3.2/lib/action_mailer/base.rb:523:in
__send__' from /Library/Ruby/Gems/1.8/gems/actionmailer-2.3.2/lib/action_mailer/base.rb:523:in
deliver!’
from
/Library/Ruby/Gems/1.8/gems/actionmailer-2.3.2/lib/action_mailer/base.rb:395:in
`method_missing’
from (irb):1
any ideas?
would really love to know where i’m going wrong, basically followed his
example below to the letter, don’t know where i’ve gone wrong.
?