-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[DOC] Edit setup content initial (#16)
Co-authored-by: Ryan Zhang <[email protected]>
- Loading branch information
1 parent
7b96327
commit c8cff1d
Showing
13 changed files
with
553 additions
and
415 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
# Using the cluster | ||
|
||
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` | ||
|
||
```shell | ||
export KUBECONFIG=~/.mke/<cluster name>.kubeconfig | ||
``` | ||
|
||
- 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 | ||
``` | ||
|
||
Example output: | ||
|
||
```text | ||
$ kubectl --context mke get nodes | ||
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 | ||
``` |
Oops, something went wrong.