-
Notifications
You must be signed in to change notification settings - Fork 93
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow overriding of keycloak root credentials for 2024.11.1
upgrade path
#2843
Conversation
needs to be validated if the keycloak_admin.get_server_info works as a first layer credential check |
src/_nebari/upgrade.py
Outdated
exit() | ||
else: | ||
# Handle other exceptions | ||
print(f"[red bold]An unexpected error occurred: {e}[/red bold]") |
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.
Will the whole stack trace be in red bold?
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 see it doesn't print out the stack trace. I agree with the comments on https://stackoverflow.com/a/1483488/9848141 that repr would be better than str(e) to give more info about what is happening.
src/_nebari/upgrade.py
Outdated
if "invalid_grant" in str(e): | ||
print( | ||
"[red bold]Failed to connect to the Keycloak server.[/red bold]\n" | ||
"[yellow]This may occur if the default admin credentials have been changed for security reasons.[/yellow]\n" |
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 feel like this makes it sound like the user did something wrong or optional when in reality changing the security credentials should be the default behaviors. I'll suggest an edit.
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.
see comments
Co-authored-by: Adam Lewis <23342526+Adam-D-Lewis@users.noreply.github.com>
… path (#2843) Co-authored-by: Adam Lewis <23342526+Adam-D-Lewis@users.noreply.github.com> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Reference Issues or PRs
closes #2833
What does this implement/fix?
Put a
x
in the boxes that applyTesting
How to test this PR?
Any other comments?