[go: up one dir, main page]

Skip to content

20250328:07 - Learning Kubernetes

Goals

It's becoming increasingly clear that I'll need some basic skills in Kubernetes (K8s) in my Support Engineering role, particularly as it relates to GitLab deployments and sysadmin. It's a topic that I've been avoiding, but I can see that within the next 6-12 months it'll be critical to at least have some level of comfort in working with k8s clusters. Of course, a big motivation is that I've been encouraged to learn about it by my manager 😉

Happily we have a couple of training modules

These are quite involved, but I think that I can follow along unofficially and do some of the readings and experiments that take my fancy.

Selected Stages

Stage 1 Background Knowledge

  1. Follow Tutorial: Kubernetes Basics
  2. Read Kubernetes Concepts
  3. Study the Kubernetes Cheatsheet
  4. Helm QuickStart
  5. Introduction to k3s
    • Try K3sup a light-weight utility to get from zero to KUBECONFIG with k3s on any local or remote VM.
  6. Learn about Octant Octant is an open source developer-centric web interface for Kubernetes that lets you inspect a Kubernetes cluster and its applications. Extremely helpful while you're learning.
  7. Trouble-Shooting Kubernetes

Stage 2: Hands-on

Basics

  1. Launch a Single-node Kubernetes Cluster using Minikube
  2. Deploy containers using kubectl
  3. Kubernetes for the Absolute Beginners
  4. Helm Package Manager

Intermediate

  1. Networking in Kubernetes
  2. Kubernetes Networking: Ingress with NGINX
  3. Kubernetes Fundamentals: Volumes and Mounts
  4. Kubernetes Volumes: Replicated MongoDB with a StatefulSet
  5. Kubernetes Fundamentals: ConfigMaps and Secrets
  6. Troubleshooting Kubernetes Applications

Stage 3: Projects

  1. Google Cloud: Set up a Cluster using gcloud command tool; you have access to a Google Cloud project via gitlabsandbox. Related questions can be directed to #sandbox-cloud-questions slack channel.

    In the Comments, provide the following:

    • The gcloud command used to create the cluster
    • Dump current cluster state
  2. Create a cluster using eksctl with Cluster Autoscaling enabled In the comments, provide the following:

    • The command used to create the cluster
    • The output after the cluster is created
    • A tail of the Cluster AutoScaler logs
  3. Deploy a sample application to a Cluster, with a Persistent Disk and Service using a YAML file In the Comments, provide the following:

    • Content of the YAML file used
    • Describe the Pod, Deployment and Service created

Stage 4: Background Helm Chart Knowledge

This stage is meant to provide your with detailed background knowledge to get you started.

Helm Charts

  1. How To Create Your First Helm Chart
  2. Building Helm Charts From the Ground Up: An Introduction to Kubernetes
  3. Helm from basics to advanced
  4. The Chart Template Developer’s Guide
  5. Introduction to Helm 3

GitLab Cloud Native Charts

  1. Architecture of Cloud native GitLab Helm charts
  2. Configuring Chart Globals
  3. Deployment Guide
  4. Storage Guide
  5. Troubleshooting

Stage 5: Hands-on Exercises

These exercises are meant to give hands-on experience

Basics

  1. Setup GKE Resources & Deploy GitLab (See item 4)
  2. Manually Setting Up Secrets
  3. Deploying GitLab
  4. Upgrading GitLab
  5. Migrating from Omnibus-GitLab package based installation

Intermediate

  1. Deploying production-ready GitLab on Google Kubernetes Engine
  2. Using External DB
  3. Using External Object Storage
  4. Using External Redis
  5. Managing Persistent Volumes after Install
  6. Using ExternalDNS
Edited by Mike Lockhart | GitLab