☸️Kubernetes Namespace
Also known as K8s Namespace, Namespace (Kubernetes), kube-system
A named area in one Kubernetes cluster. It keeps teams and apps apart.
Think of it like
It is like rooms in one house. Each room can have its own lamp, with the same name.
Example
Jack's cluster has a shop-test and a shop-live namespace. Both hold an app called web, and a test run can only touch shop-test.
Why it matters
Namespaces let many teams share one cluster safely. Each can have its own rules and its own share of the machines.
Definition
Example code
console
$ kubectl get namespace
NAME STATUS AGE
default Active 1d
kube-node-lease Active 1d
kube-public Active 1d
kube-system Active 1dCommon mistake
Key takeaways
- 1Names stay local. Unique inside a namespace, not across them.
- 2Rules per area. Limits and access are set per namespace.
- 3One level only. A namespace cannot hold another one.