Editing
Tutorials:Set up your Kubernetes user account
(section)
Jump to navigation
Jump to search
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
== Get your user credentials (an OAuth ID token) from our server == The next step is to authenticate against our server, which will then create a credential (basically a secret token which only you should know) so that you can prove to the cluster that you are indeed who you claim you are. ''Instead of the below, after recent updates, the following works:'' go to ccu-k8s.inf.uni-konstanz.de, "Login to the cluster", login, and copy and paste the displayed credentials into your shell (it starts with `kubectl config set-credentials ...`.) * Go to [https://ccu.uni-konstanz.de:32002 the dex login application] * Keep the defaults on the first screen an hit "request token" * Enter your CCU login. You will get something like this in return: <syntaxhighlight lang="yaml"> - name: your.username user: auth-provider: config: client-id: loginapp client-secret: 459679hg... id-token: eyJhbGc... idp-issuer-url: https://ccu.uni-konstanz.de:32000/dex refresh-token: ChllcHl... name: oidc </syntaxhighlight> Mark everything and copy it to the clipboard. Paste it into your kubeconfig file .kube/config below the line "users:". If you have some background in programming, the structure of the kubeconfig file should be pretty obvious, and you will be able to extend it to include e.g. multiple identities and contexts which access different namespaces. This is quite useful for quickly switching between them without having to type so much. After this step, your .kube/config should look something like this: <syntaxhighlight lang="yaml"> apiVersion: v1 clusters: - cluster: certificate-authority-data: LS0tLS1CRUdJ .... server: https://134.34.224.84:6443 name: ccu contexts: - context: cluster: ccu namespace: testing user: your.username name: me@ccu kind: Config preferences: {} users: - name: your.username user: auth-provider: config: client-id: loginapp client-secret: 459679hg... id-token: eyJhbGc... idp-issuer-url: https://ccu.uni-konstanz.de:32000/dex refresh-token: ChllcHl... name: oidc </syntaxhighlight>
Summary:
Please note that all contributions to Collective Computational Unit may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
CCU:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Navigation menu
Personal tools
Not logged in
Talk
Contributions
Create account
Log in
Namespaces
Page
Discussion
English
Views
Read
Edit
View history
More
Search
Navigation
Collective Computational Unit
Main page
Projects
Tutorials
GPU Cluster
Core Facilitys
Mediawiki
Recent changes
Random page
Help
Tools
What links here
Related changes
Page information