-
Notifications
You must be signed in to change notification settings - Fork 3
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
Intergrate Authorisation into embedded ui #311
Conversation
7cf16ed
to
80f37fb
Compare
- requires new backend
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've done some tests as first round of the review.
The login for local users works fine but there is something wrong with RedirectToError
class from shell which is causing a crash during the logout.
Minor issue:
The link in the 'URL' column to get the Epinio UI certificate in the instances table is broken.
it redirects to https://localhost:8005/api/v1/info
import { | ||
EpinioInfo, EpinioVersion, EPINIO_MGMT_STORE, EPINIO_PRODUCT_NAME, EPINIO_STANDALONE_CLUSTER_NAME, EPINIO_TYPES | ||
} from '../../types'; | ||
import EpinioCluster from '../../models/cluster'; | ||
import { RedirectToError } from '@shell/utils/error'; |
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.
RedirectToError
is not exported by @shell/utils/error
. Do we need to update the shell
dependency maybe ?
This is causing an error during logout:
Loading error Error: _shell_utils_error__WEBPACK_IMPORTED_MODULE_30__.RedirectToError is not a constructor
at Store.setError (index.js:654:1)
at wrappedMutationHandler (vuex.esm.js:844:1)
at commitIterator (vuex.esm.js:466:1)
at Array.forEach (<anonymous>)
at vuex.esm.js:465:1
at Store._withCommit (vuex.esm.js:624:1)
at Store.commit (vuex.esm.js:464:1)
at Store.boundCommit [as commit] (vuex.esm.js:409:1)
at _callee$ (authenticated.js:509:1)
at tryCatch (regeneratorRuntime.js:44:1)
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.
That was rancher/dashboard#9941, which was blocked on branching. If you yarn link
to master
the error should resolve itself.
Now that we've forked it has merged, so we can do another shell release
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've now published a new shell and referenced that from the extension
Thanks @torchiaf . I'll do the bump to shell and fix the url |
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.
Tested the Dex
login as well + a couple of comments.
}, | ||
|
||
computed: { | ||
cluster() { |
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.
Is there a specific reason to define cluster
as computed value ?
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.
Just for readability. This makes it clearer that it's a cluster, instead of an odd first entry in an array
|
||
async fetch({ store, route }: { store: any, route: any}) { | ||
const { | ||
error, error_description: errorDescription, errorCode, errorMsg |
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.
error_description
should be removed:
const {
error, errorDescription, errorCode, errorMsg
} = route.query;
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've removed errorCode and errorMsg, as these weren't used by dex or the dep to deal with oidc. error_description
is a valid param though
- can be removed once rancher/dashboard#10035 is merged and published
@torchiaf all comments should be addressed now. i've published a new verison of shell and references that as well. So no need now to |
Working on the review, thanks! |
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.
LGTM
Summary
Fixes: #358
Occurred changes and/or fixed issues
Technical notes summary
For this to work we also need to update the Dex config (see dependent PR epinio/helm-charts#504)
Depends on
Areas or cases that should be tested