Skip to main content
Version: 1.0.0

Namespace

Namespaces are a way to logically partition and isolate resources within a Kubernetes cluster. Namespaces provide a scope for names, so objects with the same name but in different namespaces will not conflict.

For example, you could have two separate namespaces called 'dev' and 'prod'. The 'dev' namespace might contain a deployment called 'myapp', while the 'prod' namespace contains a deployment also called 'myapp'. Because they are in separate namespaces, there is no naming collision. Namespaces allow you to create virtual clusters within a single physical Kubernetes cluster. This is useful for dividing development, testing and production environments so they are isolated from each other.

Namespaces are a critical concept in Kubernetes. They enable teams and projects to share a cluster while keeping their resources separated. Common use cases for namespaces include dividing workloads by team, application, customer, or environment (dev/test/prod). Overall, namespaces allow you to partition resources in a flexible way that fits your organizational requirements.