Giter Club home page Giter Club logo

multinode_kubernetes_cluster's Introduction

Multinode Kubernetes Cluster

Build Status

Kubernetes Logo

Few scripts which may help you to quickly build Multinode Kubernetes cluster. By running the scripts you got access to 4 node cluster running on VMs.

Requirements

Packages (+dependencies):

Requirements installation

  • Ubuntu 18.04
sudo apt install -y --no-install-recommends ansible curl dnsmasq ebtables git gcc jq libc-dev libvirt-bin libvirt-dev pkg-config pv qemu-kvm qemu-utils
VAGRANT_LATEST_VERSION=$(curl -s https://checkpoint-api.hashicorp.com/v1/check/vagrant | jq -r -M '.current_version')
curl https://releases.hashicorp.com/vagrant/${VAGRANT_LATEST_VERSION}/vagrant_${VAGRANT_LATEST_VERSION}_x86_64.deb --output /tmp/vagrant_x86_64.deb
sudo apt install -y /tmp/vagrant_x86_64.deb
rm /tmp/vagrant_x86_64.deb
vagrant plugin install vagrant-libvirt vagrant-hostmanager
sudo curl -L https://storage.googleapis.com/kubernetes-release/release/$(curl -s https://storage.googleapis.com/kubernetes-release/release/stable.txt)/bin/linux/amd64/kubectl --output /usr/local/bin/kubectl && sudo chmod a+x /usr/local/bin/kubectl
test -f $HOME/.ssh/id_rsa || ( install -m 0700 -d $HOME/.ssh && ssh-keygen -b 2048 -t rsa -f $HOME/.ssh/id_rsa -q -N '' )
sudo reboot
  • Fedora 28
sudo dnf install -y ansible git kubernetes-client libvirt vagrant-libvirt vagrant-hostmanager
test -f $HOME/.ssh/id_rsa || ( install -m 0700 -d $HOME/.ssh && ssh-keygen -b 2048 -t rsa -f $HOME/.ssh/id_rsa -q -N '' )
service libvirtd restart

Login Credentials

  • Username: root / vagrant
  • Password: vagrant

Usage

Make sure your system meet all requirements. For Ubuntu Xenial (16.04) you can see the installation details here: .appveyor.yml

Simply run one of the commands run-kubeadm.sh or run-kubespray.sh and wait for few minutes.

You can see the example of scripts executions here:

  • run-kubeadm.sh

asciicast

  • run-kubespray.sh

asciicast

  • run-kubeadm-demo.sh

asciicast

Once you installed the cluster use these commands to test your connection:

export KUBECONFIG=$PWD/kubeconfig.conf

kubectl get nodes
kubectl get pods --all-namespaces
kubectl cluster-info

Demo asciinema examples

  • build_kubernetes_kubeadm-demo.sh

asciicast

  • build_kubernetes_kubespray-demo.sh

asciicast

Diagrams

  • build_kubernetes_kubeadm-demo.sh

kubeadm_diagram

  • build_kubernetes_kubespray-demo.sh

kubespray_diagram

Documentation with CI

License

MIT / BSD

Author Information

Scripts were created in 2018 by [email protected]

multinode_kubernetes_cluster's People

Contributors

ruzickap avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.