Skip to content

tsl0922/kubeadm-vagrant

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

21 Commits
 
 
 
 
 
 
 
 

Repository files navigation

kubeadm-vagrant

Run kubernetes cluster with kubeadm on vagrant.

Reference: Creating Highly Available clusters with kubeadm

Requirements

  1. virtualbox: https://www.virtualbox.org/wiki/Downloads
  2. vagrant: https://www.vagrantup.com/downloads.html
  3. vagrant plugin install vagrant-hostmanager

Usage

Run vagrant up and wait for the cluster to be set up (change MASTER_COUNT to 3 to run a ha cluster).

To use kubectl on the master node, run:

vagrant ssh master # use master1 if you are running ha cluster

mkdir -p $HOME/.kube
sudo cp -Rf /etc/kubernetes/admin.conf $HOME/.kube/config
sudo chown $(id -u):$(id -g) $HOME/.kube/config

kubectl cluster-info
kubectl get nodes

Pod Network

Credits

Releases

No releases published

Packages

No packages published