mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
Authenticate with Discourse via OAuth2
See https://github.com/michaelkirk/discourse_oauth2_example for an example of how you might integrate your existing oauth2 provider's authentication via a Discourse plugin.
This commit is contained in:
14
db/migrate/20130816024250_create_oauth2_user_infos.rb
Normal file
14
db/migrate/20130816024250_create_oauth2_user_infos.rb
Normal file
@@ -0,0 +1,14 @@
|
||||
class CreateOauth2UserInfos < ActiveRecord::Migration
|
||||
def change
|
||||
create_table :oauth2_user_infos do |t|
|
||||
t.integer :user_id, null: false
|
||||
t.string :uid, null: false
|
||||
t.string :provider, null: false
|
||||
t.string :email
|
||||
t.string :name
|
||||
t.timestamps
|
||||
end
|
||||
|
||||
add_index :oauth2_user_infos, [:uid, :provider], unique: true
|
||||
end
|
||||
end
|
||||
Reference in New Issue
Block a user