Skip to content

hfmartinez/kubernetes-vagrant

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Kubernetes Cluster

Simple way to set up a kubernetes cluster with vagrant on virtualbox

System Prerequisites 📋

The following are the system prerequisites:

  • 8Gb of RAM minimum
  • 2.4GHz processor or higher
  • Git - Git
  • Virtual Box - Virtualization software.
  • Vagrant - Virtual machine management tool.

Install Environment

  • Clone the following repository by using this statement:
git clone https://github.com/hfmartinez/kubernetes-vagrant.git
  • Inside the repository folder that contains the Vagrantfile, start the virtual machines:
vagrant up
  • Run the next command to validate the installation
vagrant ssh master -c 'kubectl get nodes -o wide'

Optional Modifications

Add more workers

Change NodeCount inside Vagrantfile

Vagrant.configure(2) do |config|

  # Change to add more workers
  NodeCount = 1
  
  #global requirements
  config.vm.provision "shell", path: "requirements.sh", :args => NodeCount

Modify RAM and CPU of virtual machines

Change the following parameters inside Vagrantfile

#master
master.vm.provider "virtualbox" do |v|
    v.name = "master"
    v.memory = 2048
    v.cpus = 2
end
#workers
worker.vm.provider "virtualbox" do |v|
    v.name = "worker#{i}"
    v.memory = 2048
    v.cpus = 1
end

References

About

This project shows the implementation of a Kubernetes cluster with vagrant and flannel as a network provider.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages