Kubernetes · Production · Concepts
KAI K8s之路
Kubernetes 不是一堆 YAML。它是一組會互相影響的邊界、狀態和訊號。
這裡從 Pod 開始,把看得見的結構和看不見的生命週期拆開,讓 debug 和設計判斷更穩。
K8s map
一條主線,兩種旁路。
主線是骨架,Production 是壓力,Concepts 是工具。
Mainline
從第一個 Kubernetes 邊界開始。
主線像一張路線圖:先知道資源邊界,再看誰負責讓狀態回到正軌。
Mainline · 中文 + English
KAI K8s之路 01|Pod 是什麼?為什麼 Kubernetes 不直接管理 container
從 Kubernetes 最核心的抽象開始:Pod 到底在管什麼,為什麼平台不是直接管理單個 container,而是用 Pod 當最小調度單位。
Container 是執行單位,Pod 是編排單位。KAI K8s之路 01|Pod 是什麼?為什麼 Kubernetes 不直接管理 container
Debug workload 時先看 Pod 的排程、網路、volume 與生命週期,而不是急著背 YAML。
English versionKAI Road of Kubernetes 01 — What a Kubernetes Pod is, and why it does not manage containers directly
Start debugging from Pod placement, shared context, and lifecycle before diving into YAML details.
Production
生產環境裡,概念會變成判斷題。
Production 線記錄事故、誤判和 guardrail:例如 probe 怎麼把服務打進 restart loop,GitOps sync 前要先檢查什麼。
Kubernetes 探針誤判:一次把服務打進重啟循環的 liveness probe 事故
有些事故不是程式壞掉,而是 liveness probe 把本來還能活下來的服務誤判成該重啟。這篇記一個很典型的 production 坑。
一句判斷 健康檢查不是越兇越好;錯把慢服務殺掉,常比等它恢復更糟。
Concepts
概念要講到能拿去用。
Concepts 線整理短一點、準一點的技術模型,方便在 review、debug 或對外說明時重用。
GitOps review checklist before Argo CD syncs production
A compact pre-sync checklist for GitOps changes so an innocent YAML edit does not become surprising production behavior in Kubernetes.
Core idea GitOps applies intent; it does not prove the rollout math is safe.