Skip to content

Instantly share code, notes, and snippets.

@ardyantohermawan
Created February 7, 2018 05:18
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ardyantohermawan/0ec6d0f5272c20b8421ddd1a12b55a46 to your computer and use it in GitHub Desktop.
Save ardyantohermawan/0ec6d0f5272c20b8421ddd1a12b55a46 to your computer and use it in GitHub Desktop.
Install kubelet
#!/bin/bash
# Download latest kubectl version
curl -LO https://storage.googleapis.com/kubernetes-release/release/$(curl -s https://storage.googleapis.com/kubernetes-release/release/stable.txt)/bin/linux/amd64/kubectl
# change permission to executable binary
chmod +x ./kubectl
# move to /usr/local/bin
sudo mv ./kubectl /usr/local/bin/kubectl
# Download kubectl config from the master server, 192.168.33.10
scp root@"master ip":/etc/kubernetes/admin.conf ~/.kube/config
# We need this to run pods on master node cuz servers are expensive
kubectl taint nodes --all dedicated-
# Install weave CNI, there are other choices, but weave is probably the easist
kubectl apply -f https://git.io/weave-kube-1.6
# Install Dashboard for nice graphical web interface.
kubectl apply -f https://raw.githubusercontent.com/kubernetes/dashboard/master/src/deploy/kubernetes-dashboard.yaml
# Proxy dashboard so we can view it locally
kubectl proxy
# Set master token & IP address
kubeadm join --token="master token" "master ip"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment