-
Notifications
You must be signed in to change notification settings - Fork 14
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
Add API to get the Kubeconfig for an arbitrary UCP resource #100
Conversation
ab49add
to
1e5cd8f
Compare
Also Could you add more details on PR description regarding the changes and new APIs. Thanks |
1e5cd8f
to
7613c76
Compare
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! Thanks for the changes
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.
Overall LGTM.
Just a minor comment about adding example usage around the API doc for retrieving kubeconfig for org/project/space.
7613c76
to
33fc60b
Compare
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, some nits and a general comment about processing the kubeconfig yaml more generically but not blocking.
} | ||
|
||
// AuthInfo contains information that describes identity information. This is use to tell the kubernetes cluster who you are. | ||
type AuthInfo struct { |
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 can go with this for now, but I would like to explore whether we can process the yaml in a more generic way so we don't have to copy/maintain all this information as a followup.
- Add API to get the kubeconfig for arbitrary UCP resource given the UCP context Signed-off-by: Prem Kumar Kalle <[email protected]>
33fc60b
to
b3a6f76
Compare
What this PR does / why we need it
This PR adds API to get the kubeconfig for an arbitrary UCP resource given the UCP context
Summary:
ucp.GetKubeconfigForContext()
would construct the kubeconfig for any arbitrary UCP resource of given UCP context. It reads the kubeconfig referred by the UCP context and then updates the kubeconfig's cluster.server url to point to the requested arbitrary resource.UCP
.Which issue(s) this PR fixes
Fixes #
Describe testing done for PR
Unit tests and CI passed
Release note
Additional information
Special notes for your reviewer