-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathnotes-kubernetes.txt
49 lines (26 loc) · 1.57 KB
/
notes-kubernetes.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
20200226 -- 1
To start using your cluster, you need to run the following as a regular user:
mkdir -p $HOME/.kube
sudo cp -i /etc/kubernetes/admin.conf $HOME/.kube/config
sudo chown $(id -u):$(id -g) $HOME/.kube/config
Then you can join any number of worker nodes by running the following on each as root:
kubeadm join 172.31.3.217:6443 --token b8dv02.r6lgrai137fhyciz \
--discovery-token-ca-cert-hash sha256:91397fea9e42dc7a75409ebebbe83d5ded1c12e02681a4716f54e0247b8b256a
kubectl get nodes
sudo kubectl apply -f https://raw.githubusercontent.com/coreos/flannel/master/Documentation/kube-flannel.yml
kubectl get pods --all-namespaces
==========================
applying k8s dashboard
kubectl apply -f https://raw.githubusercontent.com/kubernetes/dashboard/v2.0.0-beta8/aio/deploy/recommended.yaml
kubectl proxy
http://localhost:8001/api/v1/namespaces/kubernetes-dashboard/services/https:kubernetes-dashboard:/proxy/
curl -LO https://storage.googleapis.com/kubernetes-release/release/`curl -s https://storage.googleapis.com/kubernetes-release/release/stable.txt`/bin/linux/amd64/kubectl
=========================
2
kubeadm join 172.31.15.190:6443 --token cabavm.byo6niaxg2okm2k6 \
--discovery-token-ca-cert-hash sha256:cc73b883940615be2fb8cf2c0d4d860c6021dce139340702a50cb32002fb1f7e
========================
3
Then you can join any number of worker nodes by running the following on each as root:
kubeadm join 172.31.2.113:6443 --token 2kdbci.8b2cb2cnhd9kxjvr \
--discovery-token-ca-cert-hash sha256:96036da75963216c1fe1a6e83dc8e1fa5af020a7e595841c21a0a26d1d2ce9f2