Running a separate Kubernetes cluster per team is expensive and operationally painful. Running a single shared cluster without proper isolation is a security and stability disaster. Multi-tenancy — safely sharing cluster resources across teams — is the practical middle ground. But Kubernetes wasn't designed for multi-tenancy. You have to build it.
Multi-Tenancy Models
Namespace-Based Tenancy
The simplest model: one namespace per team or project. Isolation provided by: RBAC (teams can only access their namespaces), resource quotas (prevent noisy neighbors), limit ranges (enforce per-container resource boundaries), and network policies (restrict cross-namespace traffic).
Strengths: simple, built into Kubernetes. Weaknesses: weak isolation for untrusted workloads, CRDs are cluster-scoped, noisy neighbor potential at the node level.
Virtual Clusters (vcluster)
Virtual clusters run inside namespaces of a host cluster. Each tenant gets their own Kubernetes API server, controller manager, and etcd — but shares the host cluster's worker nodes. Tenants can create CRDs, install operators, and manage cluster-scoped resources without affecting others.
Strengths: strong isolation, full Kubernetes API per tenant, CRD isolation. Weaknesses: additional resource overhead (each vcluster runs its own control plane), more complex operations.
Cluster-per-Tenant
Maximum isolation: each tenant gets a dedicated cluster. Managed by a central platform team via cluster-as-a-service (Rancher, Cluster API, or Crossplane). Strengths: strongest isolation, full independence. Weaknesses: highest cost, operational complexity scales linearly with tenant count.
Namespace Isolation Checklist
For namespace-based tenancy (the most common pattern), implement all of these:
- RBAC — RoleBindings scoped to namespace. No ClusterRoleBindings for tenants. Admin role per namespace tied to team's IdP group.
- Resource Quotas — CPU, memory, GPU, storage, and object count limits per namespace. Prevents any team from monopolizing cluster resources.
- Limit Ranges — Default resource requests and limits for containers. Prevents pods without resource specs from being scheduled.
- Network Policies — Default deny ingress and egress. Explicitly allow required traffic. Teams cannot communicate across namespaces unless allowed.
- Pod Security Standards — Restricted profile enforced per namespace. Prevents privilege escalation.
- Image Policies — Restrict which registries each namespace can pull from. Prevent deployment of unauthorized images.
Kubernetes Recipes
A practical guide for container orchestration and deployment by Grzegorz Stencel & Luca Berton (Apress).
Watch on Skillshare →Governance and Self-Service
Multi-tenancy works when governance is automated, not manual:
- Namespace provisioning — Self-service via Backstage or API. Creating a namespace automatically applies: RBAC bindings, resource quotas, limit ranges, network policies, and monitoring configuration.
- Policy enforcement — Kyverno or OPA Gatekeeper enforces organizational policies at admission time. No configuration drift.
- Cost allocation — Kubecost or OpenCost tracks spend per namespace. Chargeback to team budgets. Visibility drives responsible resource usage.
- Audit trail — Kubernetes audit logging captures who did what in each namespace. Essential for NIS2/DORA compliance.
Node Isolation for Sensitive Workloads
Namespace isolation operates at the Kubernetes control plane level. For defense-in-depth, add node-level isolation:
- Dedicated node pools — Taints and tolerations ensure sensitive workloads run on dedicated nodes
- Node affinity — Schedule regulated workloads to specific node groups (e.g., nodes in a specific availability zone or with specific security features)
- Runtime class — Use gVisor or Kata Containers for stronger workload isolation where kernel-level separation is required
Technical Troubleshooting
Diagnostics, networks, and customer-facing problem resolution. In collaboration with Starweaver.
Start on Coursera →What Open Empower Delivers
We design multi-tenant Kubernetes platforms for enterprises: namespace isolation, virtual clusters, governance automation, and cost allocation. Shared infrastructure that's secure, fair, and efficient.
Luca Berton
