Ensure SSO signup through signin onboards correctly on SaaS
What does this MR do and why?
Ensure sso signup through signin onboards
- before users would fall off of the onboarding process when they signed up by clicking sso buttons on the sign in page. This fixes that and ensures they continue onboarding.
Changelog: other EE: true
Screenshots or screen recordings
Before | After |
---|---|
Screen_Recording_2023-05-25_at_10.29.30_AM | Screen_Recording_2023-05-25_at_10.38.33_AM |
How to set up and validate locally
note basically trying to emulate feature spec steps in ee/spec/features/registrations/saas/standard_flow_just_me_creating_project_spec.rb
- Setup to simulate SaaS and restart GDK
- Enable ensure onboarding feature flag and
check_namespace_plan
inrails console
Feature.enable(:ensure_onboarding)
ApplicationSetting.first.update(check_namespace_plan: true)
- Setup for SSO(user github or google) and restart GDK
- set your
development
gitlab.yml
config values - mine looked like the below, setup for github by going on github under developer settings for my profile, redacted my info:
- set your
development:
<<: *base
omniauth:
block_auto_created_users: false
allow_single_sign_on: true
providers:
- { name: 'google_oauth2',
app_id: '',
app_secret: '',
args: { access_type: 'offline', approval_prompt: '' } }
- { name: 'github',
app_id: 'xxxx',
app_secret: 'xxxxx',
args: { scope: "user:email" } }
- sign in by clicking the sign in button on the sign in page for the SSO provider(with
/users/sign_in
path) and notice differences in screenshots above. - Validate when on welcome page/almost there that you can redirect to root path and it will redirect you back correctly, staying in the onboarding.
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Related to #404926
Edited by Doug Stull