DeviseSocialLogin
Add omniauth login to Rails Application via Devise. Support follwing provider:
- Github
- Line
Installation
Add this line to your application's Gemfile:
gem 'devise_social_login'
And then execute:
$ bundle
Or install it yourself as:
$ gem install devise_social_login
Usage
-
Add
omniauth_callbacks
key to the route setting:# config/routes.rb devise_for :users, controllers: { omniauth_callbacks: 'devise_social_login/omniauth_callbacks' }
-
Add provider settings to devise:
# config/initializer/devise.rb ... config.omniauth :facebook, ENV['FACEBOOK_APP_ID'], ENV['FACEBOOK_APP_SECRET'], scope: 'email', callback_url: 'http://localhost:3000/users/auth/facebook/callback' config.omniauth :twitter, ENV['TWITTER_APP_ID'], ENV['TWITTER_APP_SECRET'] ...
Contributing
Contribution directions go here.
License
The gem is available as open source under the terms of the MIT License.