Skip to content

Instantly share code, notes, and snippets.

@jzaccone
Last active December 30, 2019 21:42
Show Gist options
  • Save jzaccone/113e5f904dd261eb424ad2c6363efb48 to your computer and use it in GitHub Desktop.
Save jzaccone/113e5f904dd261eb424ad2c6363efb48 to your computer and use it in GitHub Desktop.
Setting up master for play-with-k8s
# Initializes cluster master node:
kubeadm init --apiserver-advertise-address $(hostname -i)
# Initialize cluster networking:
kubectl apply -n kube-system -f \
"https://cloud.weave.works/k8s/net?k8s-version=$(kubectl version | base64 | tr -d '\n')"
# (Optional) Initialize kube-dashboard:
curl -L -s https://git.io/kube-dashboard | sed 's/targetPort: 9090/targetPort: 9090\n type: LoadBalancer/' | \
kubectl apply -f -
# For each worker node:
kubeadm join --token ... # Copy from terminal
# On Master:
yum install git nano
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment