Skip to content

Commit 24b5373

Browse files
committed
Improve K8s setup doc.
1 parent 9b7879d commit 24b5373

File tree

1 file changed

+12
-4
lines changed

1 file changed

+12
-4
lines changed

kubernetes-basics/kubernetes-setup/README.asciidoc

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,18 +4,26 @@
44
#### Prerequisites
55
- Install link:../ansible-basics/README.asciidoc[Ansible].
66
- Install VirtualBox and Vagrant.
7-
- Install https://github.com/ahmetb/kubectx[kubectx] to help with switching context.
8-
- Install https://github.com/derailed/k9s[k9s], UI to your cluster.
97

108

119
#### Prepare K8s cluster with Vagrant and Ansible
12-
Inspired by https://kubernetes.io/blog/2019/03/15/kubernetes-setup-using-ansible-and-vagrant/
10+
```
11+
# Inspired by https://kubernetes.io/blog/2019/03/15/kubernetes-setup-using-ansible-and-vagrant/
12+
$ vagrant up
13+
$ vagrant status
14+
15+
Current machine states:
16+
17+
k8s-master running (virtualbox)
18+
node-1 running (virtualbox)
19+
node-2 running (virtualbox)
20+
```
1321

1422

1523
#### Configure kubectl in your machine
1624
```
1725
# Extract kubecofig from master node
18-
vagrant ssh k8s-master -c "sudo cat /etc/kubernetes/admin.conf" > kubeconf
26+
$ vagrant ssh k8s-master -c "sudo cat /etc/kubernetes/admin.conf" > kubeconf
1927

2028
# Add kubeconf path to $PATH
2129
# Note: KUBECONFIG only exposed to current terminal, to make it permanent add it to ~/.bashrc or /~.zshrc.

0 commit comments

Comments
 (0)