Add Google OAuth login option and update documentation#89
Open
cycomachead wants to merge 1 commit into
Open
Conversation
- Implement Google OAuth authentication as a secondary login provider - Restrict Google login to existing users matched by email (no new user creation) - Add configuration for Google Client ID, Secret, and Hosted Domain restrictions - Update User model to store email and Google ID - Add comprehensive documentation for Google Cloud setup and environment variables - Add unit tests for Google login flow and domain validation Co-authored-by: Claude Code <noreply@anthropic.com>
Coverage for unit tests for Python 3.11
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #89 +/- ##
==========================================
+ Coverage 46.08% 47.42% +1.34%
==========================================
Files 28 28
Lines 2018 2100 +82
==========================================
+ Hits 930 996 +66
- Misses 1088 1104 +16 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add Google OAuth as a secondary login option
Adds Google OAuth as an optional sign-in alternative alongside Canvas. Google login only authenticates existing users matched by email — it never creates new accounts. When Google credentials are not configured, the login flow is unchanged.
Changes
Auth flow
/login/canvas/and/login/google/routes;/login/now shows a provider chooser when Google is enabled, otherwise falls back to Canvas directlysub) is stored so subsequent logins aren't dependent on email matching aloneModel
emailandgoogle_idcolumns toUser; Canvas login now populatesemailon create/updateConfiguration
GOOGLE_CLIENT_ID,GOOGLE_CLIENT_SECRET,GOOGLE_HOSTED_DOMAINSenv vars (all optional); added toconfig.pyand.env.sampleTemplates
login.html.j2login chooser shown when Google is enabledDocs
docs/google-oauth.mdwith step-by-step Google Cloud Console setup (consent screen, OAuth client, redirect URIs, JS origins), env var reference, matching logic explanation, and troubleshooting tableREADME.mdupdated with an Authentication section linking to the docTests
Superconductor Ticket Implementation | Guided Review