Git Product home page Git Product logo

lab-cluster's Introduction

Lab Cluster

My home lab cluster.

Building your own

VM setup

  • Setup n VMs / bare metal machines with Ubuntu 18.04. The K8s control plan + etcd nodes should have 1.5 GB memory. I've given the worker nodes 8 GB memory.
  • Install docker on each VM.
wget -O - https://raw.githubusercontent.com/just1689/kubernetes-setup-rke/master/setup-node.sh | bash
  • Create a user on each VM.
  • Allow your new user to run docker x commands.
sudo usermod -aG docker $USER
  • Generate ssh keys with ssh-key-gen
  • Copy your key over to each vm with ssh-copy-id user@address
  • Turn swap off on each VM by running sudo swapoff -a
  • To allow for cleaning up as root, setup cert base ssh access to root to each VM. You may not need this. It's only for recovering from unsupported upgrade paths etc.

Installing Kubernetes

Modify the cluster.yml by changing the entries under nodes. Pay particular attention to the IP addresses, the user field and the roles.

Once the cluster.yml file reflects your desired cluster configuration run:

rke up
  • Once it is up you will find a new file called kube_config_cluster.yml
  • Overwrite your home kube config with the following command cp kube_config_cluster.yml ~/.kube/config
  • You will then be able to run kubectl get nodes and see the nodes.

Installing Apps

Longhorn

kubectl apply -f apps/01-longhorn/ 

Prometheus

kubectl apply -f apps/02-prometheus/ 

Grafana

kubectl apply -f apps/03-grafana/ 

Loki

kubectl apply -f apps/04-loki/ 

Lens

Lens can show you the cluster health of the nodes.

Lens can also show the health of your workloads. You can watch this space to see the various lab apps come up.

Issues

SCSI

sudo apt install open-iscsi -y

lab-cluster's People

Contributors

just1689 avatar

Watchers

 avatar  avatar  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.