concept

Multi-tenancy and isolation

A tenant is a team or customer whose workloads and access must be governed separately. Imagine two internal bookstore teams sharing infrastructure and a third customer running untrusted code. A namespace provides a naming and policy scope, not a standalone security sandbox. For cooperating internal teams, namespaces plus enforced controls may be appropriate. If tenants need independent cluster-scoped APIs, a virtual control plane is a candidate; if they execute hostile code or need a separate failure domain, prefer a dedicated cluster with reviewed infrastructure and isolation. Separate clusters still share risk if they use the same credentials, network or management system. Use namespace-scoped RoleBindings for API access; grant only verbs and resources needed. ResourceQuota caps aggregate declared resources, while LimitRange can set defaults and constraints. Neither makes a physical node exclusive. Apply admission controls such as restricted Pod Security where suitable and prohibit unsafe host access. Use a policy-capable CNI, ingress and egress isolation, and explicit rules for necessary DNS and application paths. NetworkPolicy does not grant API permission and cannot substitute for application authentication. Test the positive case as well as a denied case. A permitted API request does not mean a network connection is permitted.

Formal Syntax & Structure

kubernetes syntaxkubernetes
Boundary | API separation | worker separationNamespace | shared API | shared by defaultDedicated node pool | shared API | intended dedicated placementVirtual control plane | distinct tenant API | depends on implementationSeparate cluster | distinct API | verify underlying infrastructure

Working Example

Example Snippetkubernetes
1500m + 600m = 2100m > 2000m -> reject1500m + 500m = 2000m -> quota fits, scheduling not guaranteed
Kubernetes Reference