A resource quota, defined by a ResourceQuota
the object provides constraints that limit aggregate resource consumption per namespace. It can limit the number of objects that can be created in a namespace by type, as well as the total amount of computing resources that may be consumed by resources in that namespace.
create one namespace.
kubectl create namespace developer
apiVersion: v1
kind: ResourceQuota
metadata:
name: pods-medium
spec:
hard:
pods: "10"
kubectl apply -f quota.yml -n developer
kubectl describe ns developer
Name: developer
Labels: <none>
Annotations: <none>
Status: Active
Resource Quotas
Name: pods-medium
Resource Used Hard
-------- --- ---
pods 0 10
No comments:
Post a Comment