Advanced Kubernetes with DOKS

Cluster Provisioning

Nodes - 1. Master node - Manages workers
2. Worker nodes - Host applications
  1. Provisioning a DOKS cluster
  2. Configuring a local machine or a remote management server to manage DigitalOcean Kubernetes cluster
cd ~/.kube/
cp {path}/prj-kubeconfig.yaml .
doctl kubernetes cluster kubeconfig save prj # choosing cluster

3. Node pools and Sizing Kubernetes worker nodes

4. Running a sample application

kubectl run --generator=run-pod/v1 nginx-pod-name --image=nginx --replicas=1
kubectl get pods
kubectl get all

Scalable Application

  1. Deploy web applications to Kubernetes cluster for easier scaling — ReplicaSet
kubectl descibe pod nginx-pod-name        # pod has container or not
kubectl delete pod nginx-pod-name

2. Rolling out new versions and rollback of application servers

# change nginx-deployment.yaml
kubectl apply -f nginx-deployment.yaml

3. Metric server for Scaling decisions and Cluster autoscaling using HPA

kubectl scale deployment nginx-deployment --replicas=5  # scale up
kubectl scale deployment nginx-deployment --replicas=1 # scale down
# Metric server collects all the numbers and send to HPA
# HPA needs resources to be mentioned in nginx-hpa.yaml file

Persistent Storage

  1. Provision persistent storage in Kubernetes cluster — container reboots it loses the files in it

2. Exploring Storage Class, Persistent Volume Control, Persistent Volumes

3. Overview of Container Storage Interface (CSI)

4. Running StatefulSets

5. Achieving high availability of stateful workloads

Advanced Networking

  1. Load balancer, Ingress controllers and ingress resources
  2. Understanding when to use Nginx and when to use the cloud load balancer
  3. Networking plugins, CNI

Advanced Scheduling

  1. Node Affinity/Anti-Affinity
  2. Taints and Tolerations
  3. Pod Affinity/Anti-Affinity

Consultant