
Learn the fundamentals and advanced techniques of Kubernetes, from setting up clusters and deploying containers to service discovery, ingress, volumes, autoscaling, and Helm-based packaging.
Access support and download all course files, demos, and the procedure document through discussion groups, the Facebook group, or the GitHub repository at github.com/wardviaene/kubernetes-course.
What is kubernetes, why would you use it, what benefits does it give you
On Kubernetes you run containers. In this lecture you'll learn what containers are all about.
Kubernetes can run almost anywhere. You can run it on-premise or in the cloud.
This lectures explains what minikube is, a piece of software that can help you run kubernetes locally.
This demo shows you how to run Kubernetes using Minikube.
As an alternative to Minikube, you can install kubernetes using the official docker client for Mac / Windows
The difference between Minikube vs Docker client vs Kops vs Kubeadm: which one to use when
An introduction to Kops - Kubernetes Operations. Software to provision and manage Kubernetes on AWS.
Kops only works on Mac / Linux, so you'll need to setup a vagrant box to run kops. If you are running already MacOS or Linux, and you don't want to be working in a VM, you can skip this step.
You first need to open an AWS account, add an IAM user for kops and setup DNS using route53
The DNS settings need to be correct for your kubernetes cluster to work. Follow this lecture if you have issues with your DNS settings.
Once the AWS setup is complete, you can use kops to setup the Kubernetes cluster on AWS
Kubernetes only runs containers. In this lecture you learn how to build your application in a container.
In this demo I show you how to build a NodeJS example app in a container.
Once you have built a container, you need to put it on a registry, so Kubernetes can download it. You have public and private registries. Putting a container on a public registry is free.
In this demo I show you how to push the container with our app to Docker Hub
THis lecture explains how to run a first application on Kubernetes
Once the first app is available on Docker Hub, I show you how to run this app on our Kubernetes cluster
In this demo I show you some useful commands you can use to manage your containers on Kubernetes
If you're running your cluster on AWS, you can create a LoadBalancer (AWS ELB) for your application
In this demo I show you how to add an ELB (Elastic Load Balancer) to the example app
In this lecture I recap the most important concepts from the first section
In this lecture I explain the Kubernetes node architecture
You can use the replication controller to spin up multiple instances of your application
This demo shows you how to spin up multiple instances of your application
Deployment objects allow a better abstraction of an application running on Kubernetes. You can update your application version easily and roll-back if something goes wrong.
In this demo I show you how our example application can be a deployment.
Exposing our application for external traffic can be done using services
In this demo I show you how to expose our example app
Labels can be used to tag objects
Labels together with NodeSelectors can be used to run pods on a specific node
Healthchecks can be used to periodically check whether our app in the pod is still working
In this demo I show you how to use healthchecks
Learn how readiness probes, with liveness probes, ensure a pod only serves requests after startup readiness; if unhealthy, the pod's IP is removed from the service to stop traffic.
Demonstrates the difference between liveness and readiness probes using httpGet checks, initial delays, and kubectl demos to show traffic routing and container restarts.
Explore pod state by examining status, pod conditions, and container state to understand lifecycle transitions; use kubectl get pods and describe to diagnose running, pending, and failed states.
Explore the pod lifecycle, including init containers, post start and pre stop hooks, and readiness and liveness probes, with YAML configurations shaping initialization, readiness, and traffic routing.
Demonstrates a pod lifecycle with an init container and a main container, featuring readiness and liveness probes and post start and pre stop hooks with timing readouts.
Application credentials (for instance to access a database) can be stored in secrets.
Credentials can be mounted as a volume in a pod. This demo shows you how to do that.
First attempt to run a wordpress on Kubernetes. In a later version I'll show you a better way of running Wordpress on Kubernetes
Kubernetes also has a Web UI, a dashboard that makes it easy to use kubernetes
Demo explaining how to add the web UI in kops
In this brief demo I give an overview how to use the dashboard
You can do service discovery using DNS.
This is a demo showing you how service discovery works
Containers are immutable. You can still use ConfigMaps for dynamic configuration data that needs to be present on the container.
In this demo I show you how to use ConfigMap to create a custom configuration file for a standard nginx container
Ingress controller allows you to have a reverse proxy / load balancer within your Kubernetes cluster and without using an external load balancer.
In this demo I show you how to use the built-in kubernetes ingress controller
Automate External DNS records for ingress routing, linking a single load balancer to multiple apps via http rules. Support Google Cloud DNS, Route 53, Azure DNS, and Cloudflare across providers.
Demonstrates how external DNS works with a load balancer and ingress, including IAM policy setup, kube2iam considerations, and creating external DNS records for multiple hostnames helloworld-v1 and helloworld-v2.
If you want to run stateful applications on Kubernetes, you need volumes.
In this demo I show you how to use volumes in Kubernetes
Kubernetes can auto-provision volumes for you, no need to manually create an EBS volume on AWS
Now we know enough to use volumes to launch a fully working wordpress
Pod presets inject Secrets, ConfigMaps, Volumes, and environment variables into matching pods at runtime, affecting all containers. When conflicts occur, the preset does not apply.
Demonstrates enabling and using pod presets in a Kubernetes cluster, injecting environment variables and volumes into pods via an alpha feature, with steps using kops and kubectl.
Pet Sets enables you to run distributed applications and databases on Kubernetes, like ElasticSearch, MySQL Cluster, or Cassandra
In this demo I show you how to use StatefulSets with Cassandra
Daemon Sets will make sure a pod is running on every node
Resource Usage Monitoring using influxdb and grafana will give you application metrics
Starting from 1.11 Heapster will be deprecated. The replacement is the Metrics Server. This lecture explains the difference with heapster and how to install the Metrics Service.
This demo explains how to setup Resource Usage Monitoring using heapster + influxdb + grafana
Autoscaling can scale pods horizontally based on predefined targets
In this demo I show you how horizontal pod autoscaling (hpa) works
This lectures explains what Node and Interpod Affinity / Anti-affinity is and what the difference is between node affinity and the NodeSelector
This is a demo showing how Node Affinity works
Apply interpod affinity and anti-affinity to co-locate or isolate pods within the same namespace and availability zone. Use topology keys and label selectors to enforce required and preferred scheduling rules.
View a live demo of interpod affinity in Kubernetes, showing a second deployment scheduled beside the first pod. Learn how labels and the failure domain guide pod placement across nodes.
Explore how pod anti-affinity works in Kubernetes by comparing required and preferred scheduling, using topology keys to place pods on separate nodes and demonstrate results.
This lecture explains taints and tolerations, which is the opposite of node affinity
Demonstrates taints and tolerations in Kubernetes, showing how NoSchedule and NoExecute taints affect pod scheduling and how tolerations enable placing pods on tainted nodes.
This explains what Custom Resource Definitions are
Explore operators as a packaging, deployment, and management method for Kubernetes apps, using custom resource definitions to run stateful services like PostgreSQL with replicas, failover, and backups.
Learn to use the Postgres-operator to deploy, configure, and manage PostgreSQL clusters on Kubernetes, including scaling, read replicas, failover, and custom resource definitions.
This lectures gives an architecture overview of the master services
As an administrator, you can implement resource quotas to make sure one team or one person doesn't take up all resources
Namespaces can logically separate a Kubernetes cluster
In this demo I explain how to implement namespace quotas
Users can be added to your Kubernetes cluster. This lecture explains authentication and authorization
In this demo I show you how to add users using certificates
This lecture explains authorization in Kubernetes using RBAC
Learn how to create a new user with a certificate, configure a kube context, and use rbac to grant cluster-admin or namespace-scoped pod writer permissions in a Kubernetes cluster.
Every pod needs a unique IP. Not all infrastructure can easily handle this. CNI and overlay networks can help.
Sometimes you want to add / remove nodes. This is how it is done
This demo shows how to drain a Kubernetes node
Once you put a Kubernetes cluster in production, you are going to want to have full high availability. This lecture explains you how to achieve that.
This demo shows how to enable HA on your AWS Kubernetes cluster using kops
Learn how to enable TLS on AWS elastic load balancers for Kubernetes services using annotations, including TLS termination, access logs, and cross-zone routing.
Demonstrates enabling TLS on AWS ELB with AWS Certificate Manager and Route 53 DNS validation, attaching the certificate ARN and terminating TLS at the load balancer.
This lecture describes what admission controllers are in Kubernetes. It also explains what the admission controllers that are enabled by default do.
Introduction to the MutatingWebhook and ValidatingWebhook
This demo shows you how the MutatingWebhook works. For the webhook itself, we're using Golang.
This demo shows you how the MutatingWebhook works. For the webhook itself, we're using Golang.
This demo shows you how the MutatingWebhook works. For the webhook itself, we're using Golang.
Pod Security Policies allow you to fine-grain control pod security.
Demonstrates configuring pod security policies in Kubernetes with Minikube and Kops, including appending admission plugins and using privileged and restricted pod security policies. Enforces non-root runAsUser for secure containers.
etcd is the backend of Kubernetes. This lecture explains what etcd is.
Etcd uses the raft consensus algorithm. This lecture explains how raft works.
This demo shows how to backup and restore an etcd cluster when using kops
Explore how Helm packages and deploys Kubernetes apps with charts and templates. Initialize Helm, manage releases with install, upgrade, and rollback, and customize configurations via values and RBAC setup.
Install and initialize helm with tiller RBAC, deploy redis via helm charts, inspect pods and secrets, test persistence with a redis client, and upgrade or delete releases.
Create and package applications with Helm charts to deploy on Kubernetes using a single Helm install, with templates and values.yaml for dynamic yaml, and manage upgrades, rollbacks, and versioning.
Learn to create a helm chart with helm create, study chart.yaml and values.yaml defaults, and deploy nginx via templates using helm install and port forwarding.
Demonstrates building and deploying a node-app-demo helm chart with a three-replica deployment and mariadb-backed mysql configuration via environment variables.
Set up a helm repository on AWS S3 by creating a unique bucket, packaging charts, and pushing them to the repo. Verify access and prepare for CI/CD with Jenkins.
Demonstrates building and deploying a helm chart with Jenkins on Kubernetes, including RBAC, S3 bucket access, and pipeline automation to package, push, and upgrade releases.
Continuous deployment with skaffold, an open source tool by Google
A demo showing how you can develop a golang application in vscode and have every change deployed almost instantly to your Kubernetes cluster
Lecture to give an introduction to Flux and GitOps
Demo to show how to setup flux, link it to a git repository, and deploy manifests from git to a Kubernetes cluster
Explore serverless in Kubernetes by deploying functions with OpenFaas, Kubeless, Fission, or OpenWhisk, and learn how public cloud options like AWS Lambda reduce operational costs despite potential cold starts.
Explore Kubeless, a Kubernetes-native framework that uses custom resource definitions to deploy functions in languages like Python and NodeJS, with HTTP, scheduled, and Kafka, NATS, or AWS Kinesis pub-sub triggers.
Install Kubeless on your Kubernetes cluster and deploy your first function using Python or NodeJS, then expose it via an HTTP trigger with an ingress.
Learn to deploy a Kubeless function triggered by a Kafka topic that converts input to uppercase within a Kubernetes serverless setup.
Discover how microservices and service meshes improve Kubernetes with Istio, using envoy sidecars for encrypted communication, retries, intelligent load balancing, and centralized telemetry, access control, and routing.
Launch a new kops cluster with t2 medium nodes for Istio memory, edit kubeAPIServer admissionControl, then download Istio, apply CRDs, and install Istio with no mutual TLS.
Demonstrate deploying a hello world microservice with Istio and Envoy sidecars in a Kubernetes cluster. Route traffic through an Istio ingress gateway and virtual service to illustrate multi-service communication.
Explore advanced traffic routing with Istio by directing requests to hello v1 or v2 via virtual service rules, destination rules, and header-based matching.
Demonstrate canary deployments in Kubernetes by routing 90% to v1 and 10% to v2 using canary.yaml, then apply with kubectl and verify results with repeated curl checks.
See how Istio retries reroute traffic from slow pods to healthy ones. The demo uses hello world v3 with two deployments, a five-second latency, a 10-second timeout, and two retries.
Explore mutual TLS in Istio to secure service-to-service communications with automatic certificate management, strong identity, and end-to-end encryption, all without changing application code, within your cluster.
Demonstrates enabling mutual TLS in a Kubernetes cluster with Istio across ESTL enabled namespaces and a legacy namespace, detailing gateways, destination rules, and testing with curl.
Enforce service-to-service and end-user-to-service authorization with Istio RBAC and mutual TLS, using SPIFFE identities and x.509 certificates; define service roles and bindings to limit access, demonstrated in a default namespace.
Demonstrates RBAC with Istio in a helloworld demo, enabling mtls via mesh policy and destination rule, binding service roles to service accounts, and validating access via gateway and virtual service.
Learn end-user authentication with istio using JWT tokens, RS256 signing, and public key verification to secure access to a hello app without embedding auth logic in services.
Demonstrate end-user authentication with a jwt in Istio, using gateways and virtual services with jwks.json to verify tokens and enforce MTLS.
Enable Istio egress traffic by configuring ServiceEntry and VirtualService for external hosts on a per service basis, enabling selective access through Envoy for http and https.
Illustrates distributed tracing with jaeger in a multi-service flow from istio-ingress to hello, world, and world-2 apps, forwarding open-trace headers for end-to-end debugging.
Explore Grafana dashboards for Istio metrics, drill into the Istio service, Mixer, and Pilot dashboards, and monitor traffic and service health across istio-system.
This course will help you to gain understanding how to deploy, use, and maintain your applications on Kubernetes. If you are into DevOps, this is a technology you need to master. Kubernetes has gained a lot of popularity lately and it is a well sought skill by companies.
This course is updated frequently to include the features of latest releases!
When Google started running containers a decade ago, nobody could reach this kind of infrastructure agility and efficiency. Using this knowledge, Google released Kubernetes as an free and open source project. Nowadays Kubernetes is used by small companies and big enterprises who want to gain the efficiency and velocity Google has.
You can containerize applications using Docker. You can then run those containers on your servers, but there's no way you can manage those efficiently without extra management software. Kubernetes is an orchestrator for your containers that will create, schedule and manage your containers on a cluster of servers. Kubernetes can run on-premise or in the cloud, on a single machine or on thousands of machines.
I will show you how to build apps in containers using docker and how to deploy those on a Kubernetes cluster. I will explain you how to setup your cluster on your desktop, or on the cloud using AWS. I use a real world example app (Wordpress with MySQL - blogging software) to show you the real power of Kubernetes: scheduling stateless and stateful applications.
The introduction lectures that show you the Kubernetes desktop installation are free to preview, so you can already have a go at it before buying the course!
This course also has Closed Captions (English subtitles)
Updates (11/2019):
* Added Admission Controllers lectures
* Continuous Development with Skaffold
* etcd and the raft algorithm
Updates (01/2020):
* AWS EKS (managed Kubernetes) lecture and demo
Updates (01/2021):
* MutatingWebhook, ValidatingWebhook and demo
Updates (04/2024):
* How to write a Kubernetes Operator Controller in Go