What if one team's app crashes the whole cluster because it used too many resources? Resource quotas stop that from happening.
Why Resource quotas per namespace in Kubernetes? - Purpose & Use Cases
Imagine you manage a shared playground where many kids want to play with limited toys. Without rules, some kids grab all the toys, leaving none for others.
Manually tracking who uses what resources in a Kubernetes cluster is like watching every kid all the time. It's slow, tiring, and mistakes happen--some teams use too much, others get none.
Resource quotas per namespace set clear limits on how much each team can use. This way, everyone gets a fair share automatically, and the system keeps things balanced without constant watching.
No limits set; teams deploy freely and can consume all resources.apiVersion: v1
kind: ResourceQuota
metadata:
name: team-quota
namespace: team-namespace
spec:
hard:
pods: '10'
requests.cpu: '4'
requests.memory: 8Gi
limits.cpu: '8'
limits.memory: 16GiIt enables fair, automatic sharing of cluster resources so no team can accidentally block others.
A company runs multiple projects in one Kubernetes cluster. Using resource quotas per namespace, each project gets a fixed amount of CPU and memory, preventing one project from crashing the whole system.
Manual resource tracking is slow and error-prone.
Resource quotas set clear, automatic limits per namespace.
This keeps cluster resources fairly shared and stable.