From 48031dde29d6dc4a0ba84c445ae4c07627257d4a Mon Sep 17 00:00:00 2001 From: hellekin Date: Mon, 5 Oct 2020 21:51:37 +0200 Subject: Configure Discourse SSO We're creating a minimal User model that will be filled from SSO. We also configure Inflections so we can use SSO instead of Sso which looks weird for a module named after an acronym. Use Discourse as SSO: https://meta.discourse.org/t/using-discourse-as-a-sso-provider/32974 --- db/migrate/20201005154823_create_users.rb | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 db/migrate/20201005154823_create_users.rb (limited to 'db/migrate') diff --git a/db/migrate/20201005154823_create_users.rb b/db/migrate/20201005154823_create_users.rb new file mode 100644 index 0000000..2d8403c --- /dev/null +++ b/db/migrate/20201005154823_create_users.rb @@ -0,0 +1,15 @@ +class CreateUsers < ActiveRecord::Migration[6.0] + def change + create_table :users do |t| + t.string :name + t.string :username + t.string :email + t.bigint :external_id + t.string :avatar_url + + t.timestamps + end + add_index :users, [:external_id], unique: true + add_index :users, [:email], unique: true + end +end -- cgit v1.2.3