Skip to content

same7ammar/kubernetes-from-scratch

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Kubernetes Hands-On Course

8-Session Lab Guide for Intermediate Developers

Cluster: this repo is configured for kind (kind create cluster --name k8s-labs). All commands, port mappings, and image-load instructions use kind defaults.


The Big Project: Incident Tracker

Every session adds a new Kubernetes concept to one evolving real application: a full-stack Incident Tracking system.

Layer Technology Image
Backend API Node.js + Express incident-api:v1 / v2
Frontend UI React + Vite (served by nginx) incident-frontend:v1
Database PostgreSQL 15 postgres:15-alpine (public)

API endpoints:

Method Path Description
GET /health Version + storage mode
GET /incidents List all incidents
POST /incidents Create { title, severity }

Storage auto-detection: when POSTGRES_PASSWORD is set the backend switches to PostgreSQL automatically; otherwise it runs with an in-memory array. Same image, no rebuild needed between sessions.


Quick Start — Build the Images

Run this once before Session 1 (or after recreating your cluster).

# 1. Create the kind cluster
kind create cluster --name k8s-labs
kubectl cluster-info --context kind-k8s-labs

# 2. Build images and load them into the cluster
chmod +x app/build.sh
./app/build.sh kind

# 3. Verify the images are available
docker exec kind-k8s-labs-control-plane crictl images | grep incident

Images produced and loaded:

Image First used in
incident-api:v1 Session 1

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors