-
Notifications
You must be signed in to change notification settings - Fork 16
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
[DOC] Edit setup content initial #16
Changes from 13 commits
3c981e4
c9b2db0
f5e1bcc
8012fb3
22f09bd
c6c2e3a
19db78f
ccba35c
77cfadf
5c35835
a94a19d
88bc9a9
8e7e2a5
30f5b7a
4e0849d
5c37935
7e89154
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
This file was deleted.
Original file line number | Diff line number | Diff line change | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
@@ -0,0 +1,45 @@ | ||||||||||||
|
||||||||||||
|
||||||||||||
## Using the cluster | ||||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||||||||
|
||||||||||||
You can use `kubectl` with the `mke` context to interact with the cluster, | ||||||||||||
though it is necessary to specify the configuration. `mkectl` outputs the | ||||||||||||
kubeconfig of the cluster to `~/mke/.mke.kubeconfig`. | ||||||||||||
|
||||||||||||
You can apply ``.mke.kubeconfig`` using any one of the following methods: | ||||||||||||
|
||||||||||||
- Set the KUBECONFIG env var to point to `~/.mke/mke.kubeconfig` | ||||||||||||
|
||||||||||||
Example: | ||||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Remove, other methods don't have it. |
||||||||||||
|
||||||||||||
```shell | ||||||||||||
`export KUBECONFIG=~/.mke/<cluster name>.kubeconfig` | ||||||||||||
``` | ||||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||||||||
|
||||||||||||
- Append the contents to the default kubeconfig: | ||||||||||||
|
||||||||||||
```shell | ||||||||||||
`cat ~/.mke/mke.kubeconfig >> ~/.kube/config` | ||||||||||||
``` | ||||||||||||
|
||||||||||||
- Specify the config as a command argument: | ||||||||||||
|
||||||||||||
```shell | ||||||||||||
`kubectl --kubeconfig ~/.mke/mke.kubeconfig` | ||||||||||||
``` | ||||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||||||||
|
||||||||||||
Example output: | ||||||||||||
|
||||||||||||
```text | ||||||||||||
$ kubectl --context mke get nodes | ||||||||||||
nwneisen marked this conversation as resolved.
Show resolved
Hide resolved
|
||||||||||||
NAME STATUS ROLES AGE VERSION | ||||||||||||
node1 Ready <none> 2d v1.29.3+k0s | ||||||||||||
node2 Ready control-plane 2d v1.29.3+k0s | ||||||||||||
``` | ||||||||||||
|
||||||||||||
To modify the cluster configuration, edit the YAML configuration file and | ||||||||||||
rerun the `apply` command. | ||||||||||||
|
||||||||||||
```shell | ||||||||||||
mkectl apply -f mke.yaml | ||||||||||||
``` |
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.
Remove empty lines