User-defined Playground

Kubernetes the Hard Way Playground

A manually assembled Kubernetes cluster, inspired by Kelsey Hightower's "Kubernetes the Hard Way" tutorial.

Startup configuration
dev-machine
control-plane
worker-01
worker-02
Kubernetes the Hard Way playground: A manually assembled Kubernetes cluster, inspired by Kelsey Hightower's "Kubernetes the Hard Way" tutorial.

Welcome to the Kubernetes the Hard Way lab environment!

This playground is inspired by Kelsey Hightower's legendary tutorial of the same name...

... with one key difference: everything is already set up and ready for you to explore!

No need to manually provision VMs on a cloud provider or spend hours configuring each component from scratch.

The goal of this playground is to provide a learning environment for exploring and understanding the inner workings of a Kubernetes cluster.

The configuration and operational practices presented here are NOT recommended for production use.

Try this at home (not at work!)

People often say "don't try this at home" when they're doing something dangerous.

In this case, you should try this at home instead of at work.

Your production clusters will thank you for learning the hard way in a safe environment first! 😉

What makes this different?

This lab environment provides the end result of Kelsey's tutorial: a fully functional, manually assembled Kubernetes cluster where every component runs as a systemd service (rather than as containers).

Instead of spending hours setting up cloud VMs and configuring each component, you can jump straight into exploring and learning from a working "hard way" cluster.

In addition to Kelsey's original tutorial setup, this lab also includes:

  • CoreDNS for DNS resolution within the cluster
  • Flannel as a network addon (replacing static routes for Pod networking)

Architecture overview

This cluster consists of multiple nodes running various Kubernetes components as systemd services. The architecture follows the traditional Kubernetes design, but with everything running on the host system rather than in containers.

Control Plane

The control plane runs the core Kubernetes services that manage cluster state and make scheduling decisions.

Control plane components

Control plane components

These components are essential for the control plane to function properly:

ComponentRole
etcdDistributed key-value store that holds all cluster data.
kube-apiserverThe heart and soul of the Kubernetes control plane, exposing the Kubernetes API.
kube-controller-managerManages various controllers that maintain the desired state of the cluster.
kube-schedulerSchedules Pods onto Nodes based on resource availability and other constraints.
CoreDNS (optional)Provides DNS resolution and service discovery for the cluster.

Worker nodes

Worker nodes run the actual workloads and provide the runtime environment for pods.

Worker node components

Worker node components

ComponentRole
kubeletPrimary node agent that ensures containers are running in pods.
Container Runtime (containerd)Manages container creation, execution, and cleanup.
Network addon (flannel)Provides networking for pod-to-pod communication.
kube-proxyNetwork proxy that maintains network rules on nodes for service networking.

Getting Started

  1. Explore the environment: Each component's systemd service file shows exactly how Kubernetes components are configured
  2. Check service status: Use systemctl status <service-name> to see the health of each component
  3. Review logs: Use journalctl -u <service-name> to view detailed logs for troubleshooting
  4. Modify configurations: Edit service files and restart services to see how changes affect the cluster
  5. Break things safely: This is a learning environment—experiment with stopping services or changing configurations

(Kinda) Certified

Here's a fun fact: this manually assembled, systemd-managed Kubernetes cluster actually passes the sonobuoy conformance tests!

This means our "distribution" of Kubernetes could technically be submitted for official CNCF certification. Of course, we're not going to certify "Kubernetes the Hard Way on systemd" as an official distribution, but it's impressive that a cluster assembled entirely by hand can meet the same standards as enterprise-grade Kubernetes platforms.

This demonstrates that under the hood, Kubernetes is "just" a collection of well-designed, interoperable components.

So congratulations—you're playing with a (kinda) certified Kubernetes distribution! 🎉

Start
Settings