[ARVADOS] created: 360d5f885a6613a506e283ff74b18382249cf929

Git user git at public.curoverse.com
Wed Oct 19 17:15:01 EDT 2016


        at  360d5f885a6613a506e283ff74b18382249cf929 (commit)


commit 360d5f885a6613a506e283ff74b18382249cf929
Author: Peter Amstutz <peter.amstutz at curoverse.com>
Date:   Wed Oct 19 17:14:51 2016 -0400

    10287: When creating a new account, if provided use 'username' from SSO server.

diff --git a/services/api/app/controllers/user_sessions_controller.rb b/services/api/app/controllers/user_sessions_controller.rb
index 795b114..e25b4a4 100644
--- a/services/api/app/controllers/user_sessions_controller.rb
+++ b/services/api/app/controllers/user_sessions_controller.rb
@@ -44,6 +44,7 @@ class UserSessionsController < ApplicationController
                       :last_name => omniauth['info']['last_name'],
                       :identity_url => omniauth['info']['identity_url'],
                       :is_active => Rails.configuration.new_users_are_active,
+                      :username => omniauth['info']['username'],
                       :owner_uuid => system_user_uuid)
       act_as_system_user do
         user.save or raise Exception.new(user.errors.messages)
diff --git a/services/api/lib/josh_id.rb b/services/api/lib/josh_id.rb
index a7e8ff2..1a6e38a 100644
--- a/services/api/lib/josh_id.rb
+++ b/services/api/lib/josh_id.rb
@@ -17,6 +17,7 @@ module OmniAuth
           :last_name => raw_info['info']['last_name'],
           :email => raw_info['info']['email'],
           :identity_url => raw_info['info']['identity_url'],
+          :username => raw_info['info']['username'],
         }
       end
 

-----------------------------------------------------------------------


hooks/post-receive
-- 




More information about the arvados-commits mailing list