On-Prem Deployment Instruction Set

Here are the detailed instructions that can be executed on the server to execute the Tellius installation. It starts with setting up the dockers, deploying Kubernetes services and then installing the Tellius software.

  1. Current User information

We will need to know the username of the current login credentials for few instructions in this process.

export CURRENTUSER=`whoami`

  1. Configuring the repository managers

Docker repositories need to be configured to download docker and epel release repositories need to be enabled for installing python.

sudo yum install -y yum-utilssudo yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.reposudo yum makecache fastsudo rpm -ivh https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm

sudo yum update

  1. Installing tools to access docker images

Installing Docker as all the services run as Docker containers.

Installing generic tools like curl, wget to download files and python, pip and awscli to connect to AWS as the docker images are stored in AWS Elastic Container service.

sudo yum -y install --setopt=obsoletes=0 docker-ce-17.03.2.ce-1.el7.centos docker-ce-selinux-17.03.2.ce-1.el7.centossudo yum -y install ca-certificates curl wgetsudo yum -y install epel-release python-pipsudo pip install --upgrade awscli virtualenv pip

  1. Disable Swap

Kubernetes requires swap to be disabled.

sudo swapoff -a

  1. Add current user to Docker group

This will enable the current user to access docker service through docker commands

sudo usermod -a -G docker $CURRENTUSER

  1. Restart docker, wait for 10 seconds and print the docker info

sudo systemctl restart dockersleep 10docker info

  1. Configure repository for Kubernetes tool

Kubernetes repository has to be configured in yum.repos.d

sudo sh -c 'cat <<EOF > /etc/yum.repos.d/kubernetes.repo[kubernetes]name=Kubernetesbaseurl=https://packages.cloud.google.com/yum/repos/kubernetes-el7-x86_64enabled=1gpgcheck=1repo_gpgcheck=1gpgkey=https://packages.cloud.google.com/yum/doc/yum-key.gpg https://packages.cloud.google.com/yum/doc/rpm-package-key.gpgEOF'

  1. Install Kubernetes tools- kubeadm, kubelet, kubernetes-cni

Kubeadm - Command to bootstrap the cluster, kubelet - component of Kubernetes which manages containers and kubernetes-cni - manages networking in/with Kubernetes

sudo yum install -y kubeadm-1.10.0 kubelet-1.10.0 kubernetes-cni-0.6.0sudo systemctl start kubelet

  1. Change the cgroup driver configuration from systemd to cgroupfs in kubeadm.conf

In RHEL, Kubeadm doesn’t recognize the cgroup driver automatically. It should be changed to cgroupfs manually.

sudo sed -i "s/cgroup-driver=systemd/cgroup-driver=cgroupfs/g" /etc/systemd/system/kubelet.service.d/10-kubeadm.conf

  1. Restart Kubelet

Restart kubelet to pickup the above configuration changes

sudo systemctl daemon-reloadsudo systemctl restart kubelet

  1. Initialize Kubeadm

Initialize kubeadm and bootstrap a new kubernetes cluster

sudo kubeadm init --kubernetes-version=v1.10.13 --ignore-preflight-errors=all --pod-network-cidr=

  1. Install Kubectl

Command line utility to interact with Kubernetes cluster

curl -LO https://storage.googleapis.com/kubernetes-release/release/v1.10.0/bin/linux/amd64/kubectl

  1. Setup Kubernetes config in home directory

Kubernetes server configuration should be stored in the home directory for kubectl to use this configuration to interact with the server.

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

  1. Check the pods created

There should be kubernetes' system pods up and running

kubectl get po --namespace=kube-system

  1. Pull the configuration files in Tellius deployment tar.gz

Configuration files for different services of Tellius application and also plugins are stored in the tar file, download and extract it into Tellius-deploy

mkdir -p Tellius-deploywget -qO- https://s3.amazonaws.com/tellius-deploy/Tellius-Deploy-2.4.tar.gz | tar xvz -C Tellius-deploycd Tellius-deploy

  1. Setup flannel to set up networking within Kubernetes nodes

Add Flannel, Kubernetes networking addon to configure iptables rules

kubectl apply -f flannel/kube-flannel.yaml

  1. Taint the nodes and wait for 20 seconds to complete the taint

Master would have a taint of not scheduling any pods on it, we will have to remove the restriction as we have deployed Kubernetes as a pseudo distributed mode where master also acts as a slave.

kubectl taint nodes --all=true node-role.kubernetes.io/master:NoSchedule-

  1. Deploy dashboard pod

Create a dashboard for monitoring the Kubernetes resources.

kubectl apply -f deploy-scripts/kubernetes-dashboard.yamlkubectl create -f deploy-scripts/dashboard-admin.yaml

  1. Run the start script of Tellius

Run the start script which starts all the services of Tellius application in containers.


Did we help you?

Installation Overview