choonkeat / runtimeerror_notifier

runtimeerror_notifier gem for those without email sending resources
Other
2 stars 1 forks source link

SSL does not match when `db:migrate` on heroku server #6

Closed allenlsy closed 9 years ago

allenlsy commented 9 years ago

When I tried to do db migration on my heroku server, it stops due to this error:

  Rendered vendor/bundle/ruby/2.2.0/gems/runtimeerror_notifier-0.0.27/templates/runtimeerror_notifier/_request.html.erb (0.9ms)
  Rendered vendor/bundle/ruby/2.2.0/gems/runtimeerror_notifier-0.0.27/templates/runtimeerror_notifier/_title.html.erb (0.4ms)
  Rendered vendor/bundle/ruby/2.2.0/gems/runtimeerror_notifier-0.0.27/templates/runtimeerror_notifier/_session.html.erb (0.6ms)
  Rendered vendor/bundle/ruby/2.2.0/gems/runtimeerror_notifier-0.0.27/templates/runtimeerror_notifier/_title.html.erb (0.1ms)
  Rendered vendor/bundle/ruby/2.2.0/gems/runtimeerror_notifier-0.0.27/templates/runtimeerror_notifier/_environment.html.erb (3.0ms)
  Rendered vendor/bundle/ruby/2.2.0/gems/runtimeerror_notifier-0.0.27/templates/runtimeerror_notifier/_title.html.erb (0.1ms)
  Rendered vendor/bundle/ruby/2.2.0/gems/runtimeerror_notifier-0.0.27/templates/runtimeerror_notifier/_backtrace.html.erb (0.4ms)
  Rendered vendor/bundle/ruby/2.2.0/gems/runtimeerror_notifier-0.0.27/templates/runtimeerror_notifier/_title.html.erb (0.1ms)
  Rendered vendor/bundle/ruby/2.2.0/gems/runtimeerror_notifier-0.0.27/templates/runtimeerror_notifier/notification_mail.html.erb (18.3ms)
/app/vendor/ruby-2.2.2/lib/ruby/2.2.0/openssl/ssl.rb:232:in `post_connection_check': hostname "runtimeerror.net" does not match the server certificate (OpenSSL::SSL::SSLError)
    from /app/vendor/ruby-2.2.2/lib/ruby/2.2.0/net/http.rb:925:in `connect'
    from /app/vendor/ruby-2.2.2/lib/ruby/2.2.0/net/http.rb:863:in `do_start'
    from /app/vendor/ruby-2.2.2/lib/ruby/2.2.0/net/http.rb:852:in `start'
    from /app/vendor/ruby-2.2.2/lib/ruby/2.2.0/net/http.rb:1375:in `request'
    from /app/vendor/bundle/ruby/2.2.0/gems/httparty-0.13.5/lib/httparty/request.rb:101:in `perform'
    from /app/vendor/bundle/ruby/2.2.0/gems/httparty-0.13.5/lib/httparty.rb:522:in `perform_request'
    from /app/vendor/bundle/ruby/2.2.0/gems/httparty-0.13.5/lib/httparty.rb:476:in `post'
    from /app/vendor/bundle/ruby/2.2.0/gems/httparty-0.13.5/lib/httparty.rb:564:in `post'
    from /app/vendor/bundle/ruby/2.2.0/gems/runtimeerror_notifier-0.0.27/lib/runtimeerror_notifier/notifier.rb:51:in `make_request'
    from /app/vendor/bundle/ruby/2.2.0/gems/runtimeerror_notifier-0.0.27/lib/runtimeerror_notifier/notifier.rb:43:in `notification_mail'
    from /app/vendor/bundle/ruby/2.2.0/gems/actionpack-4.1.11/lib/abstract_controller/base.rb:189:in `process_action'
    from /app/vendor/bundle/ruby/2.2.0/gems/actionpack-4.1.11/lib/abstract_controller/callbacks.rb:20:in `block in process_action'
    from /app/vendor/bundle/ruby/2.2.0/gems/activesupport-4.1.11/lib/active_support/callbacks.rb:82:in `run_callbacks'
    from /app/vendor/bundle/ruby/2.2.0/gems/actionpack-4.1.11/lib/abstract_controller/callbacks.rb:19:in `process_action'
    from /app/vendor/bundle/ruby/2.2.0/gems/actionpack-4.1.11/lib/abstract_controller/base.rb:136:in `process'
    from /app/vendor/bundle/ruby/2.2.0/gems/actionview-4.1.11/lib/action_view/rendering.rb:30:in `process'
    from /app/vendor/bundle/ruby/2.2.0/gems/actionmailer-4.1.11/lib/action_mailer/base.rb:580:in `block in process'
    from /app/vendor/bundle/ruby/2.2.0/gems/activesupport-4.1.11/lib/active_support/notifications.rb:159:in `block in instrument'
    from /app/vendor/bundle/ruby/2.2.0/gems/activesupport-4.1.11/lib/active_support/notifications/instrumenter.rb:20:in `instrument'
    from /app/vendor/bundle/ruby/2.2.0/gems/activesupport-4.1.11/lib/active_support/notifications.rb:159:in `instrument'
    from /app/vendor/bundle/ruby/2.2.0/gems/actionmailer-4.1.11/lib/action_mailer/base.rb:577:in `process'
    from /app/vendor/bundle/ruby/2.2.0/gems/actionmailer-4.1.11/lib/action_mailer/base.rb:568:in `initialize'
    from /app/vendor/bundle/ruby/2.2.0/gems/actionmailer-4.1.11/lib/action_mailer/base.rb:551:in `new'
    from /app/vendor/bundle/ruby/2.2.0/gems/actionmailer-4.1.11/lib/action_mailer/base.rb:551:in `method_missing'
    from /app/vendor/bundle/ruby/2.2.0/gems/runtimeerror_notifier-0.0.27/lib/runtimeerror_notifier/notifier.rb:27:in `notification'
    from /app/vendor/bundle/ruby/2.2.0/gems/runtimeerror_notifier-0.0.27/lib/runtimeerror_notifier/rake_handler.rb:13:in `display_errors_with_runtimeerror'
    from /app/vendor/ruby-2.2.2/lib/ruby/2.2.0/rake/application.rb:185:in `rescue in standard_exception_handling'
    from /app/vendor/ruby-2.2.2/lib/ruby/2.2.0/rake/application.rb:176:in `standard_exception_handling'
    from /app/vendor/ruby-2.2.2/lib/ruby/2.2.0/rake/application.rb:75:in `run'
    from /app/bin/rake:8:in `<main>'

My heroku server has added a SSL :: endpoint, so is this a problem with runtimeerror.net?

But when I do db migration on heroku on another server which does not has a SSL::Endpoint add-on, the migration works

choonkeat commented 9 years ago

what's your RUNTIMEERROR_URL env variable? it should be http://js.runtimeerror.net/incoming_emails and thus shouldn't be accessed via SSL

allenlsy commented 9 years ago

https://js.runtimeerror.net/incoming_emails

After change it to http, now it works. Thanks choonkeat

choonkeat commented 9 years ago

:clap: :clap: :clap: :clap: