when using OmniAuth in rails application why I always met Errno::ETIMEDOUT
-
24-10-2019 - |
Question
I have a rails dummy application, And I've add OmniAuth into my Gemfile. I've add
<%= link_to "Sign in with Twitter", "/auth/twitter" %>
in my application layout file.
Also I've add the omniauth.rb file in my config\initializers folder.
Rails.application.config.middleware.use OmniAuth::Builder do
provider :twitter, 'MYKEY', 'MYSECERT'
end
After I restart of my rails server with rails s
and visit http://localhost:3000/auth/twitter
I've always met Errno::ETIMEDOUT
, saying Operation timed out - connect(2)
My computer can visit Twitter website meanwhile.
Can anyone help me what was going wrong here? Thank you very much.
Solution
That is because of the network issue. After connected with VPN, everything was fine.
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow