- Notifications
You must be signed in to change notification settings - Fork928
feat: Allow hiding password auth, changing OpenID Connect text and OpenID Connect icon#5101
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
feat: Allow hiding password auth, changing OpenID Connect text and OpenID Connect icon#5101
Uh oh!
There was an error while loading.Please reload this page.
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
Hey 👋 I appreciate the contribution!
I think we'll want to end up disabling password authentication instead of hiding it for security reasons. I'll review this later today!
@kylecarbs and I just had a chat and decided we shouldn't completely disable the password login so the default However, we can put it behind a backdoor (e.g. |
Implemented With the following env vars set:
|
This Pull Request is becoming stale. In order to minimize WIP, prevent merge conflicts and keep the tracker readable, I'm going close to this PR in 3 days if there isn't more activity. |
# Conflicts:#cli/deployment/config.go#cli/server.go#cli/testdata/coder_server_--help.golden#coderd/userauth.go#codersdk/deploymentconfig.go#docs/admin/auth.md#site/src/api/typesGenerated.ts#site/src/components/SignInForm/SignInForm.tsx
This Pull Request is becoming stale. In order to minimize WIP, prevent merge conflicts and keep the tracker readable, I'm going close to this PR in 3 days if there isn't more activity. |
@kylecarbs how would an owner/admin sign in if we disable password auth? As@bpmct proposed, we could put it behind |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
Backend changes look good to me with one minor request if we keep the flag.
Uh oh!
There was an error while loading.Please reload this page.
I think I'd prefer if we did a small "Login with Password" link at the bottom that would permit authenticating with a password. It's awkward to not allow it, since in emergency situations it would be required. An alternative is to take the stance that owners/admins should be able to modify the deployment, so they could always disable this feature. |
I can get behind a small link as long as it's clear that SSO is preferred. Many login forms tend to have both even if 99% of an organization's users use SSO |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
This UX LGTM! Thanks for the contribution, let's ship it 🚢
<div> | ||
<LoadingButton | ||
loading={isLoading} | ||
{showPasswordAuth && ( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
We have some new conditionals in this file introduced by the new booleans:nonPasswordAuthEnabled
andshowPasswordAuth
. Considering the file is getting fairly large, it might be nice to break the JSX inside these conditionals into separate components in separate files. This will make everything a bit more readable. Not a blocker though!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
I agree
I took a hack at it (might have made a few stylistic choices, open to feedback)
Also turned thesevar &&
into<Maybe
s as I saw that used all over the codebase (and might have to steal that for myself)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
Looks beautiful! Thanks for leaving things better than you found them :)
Uh oh!
There was an error while loading.Please reload this page.
github-actionsbot commentedJan 20, 2023 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
CLA Assistant Lite bot All contributors have signed the CLA ✍️ ✅ |
6e20df2
to1ed7911
Comparenormana10 commentedJan 20, 2023 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
Oops sorry pushed the golden files update from a different computer |
@normana10 seems like |
Feel free I keep trying to run Then I do a And I get a:
(On my Mac) Which.... totally makes sense, I don't have Docker installed on my Mac Buuuut, when I try the same on my Fedora computer it ends up erroring out with a:
But... |
@normana10 sorry the error is so unhelpful, you'll need to have |
🤷 |
Wait I just noticed that Just symlinked my install of Pushing up now |
That was a roller coaster but I think it's all good now? 👍 Thanks! |
Woot woot. Thanks for pushing through@normana10 🥳 |
@normana10 can you merge in |
Done Sorry if I caused any issues 😬 |
@normana10 we're now using this onhttps://dev.coder.com 😎 |
Uh oh!
There was an error while loading.Please reload this page.
Just some ideas to help decrease friction in onboarding developers to my coder deployment
For context, my users willnever use password auth, only Oauth
Examples:
I only reference Gitea because that's my OpenID Connect provider at home, feel free to replace that with anything you like 👍
I also acknowledge that I'm changing the shape of the return body of
api/v2/users/authmethods
. Not sure if that's a deal breaker?Also let me know if Coderintentionally didn't want to do any of these. Don't want my random PRs to steamroll any actual conversations that have taken place