ResourceQuota Profile

2 min read

A ResourceQuota profile is a named preset that expands into a complete Kubernetes ResourceQuota hard limits block at reconcile time.

You write a profile name. Orkestra writes the pod counts, CPU, and memory limits for the namespace.


Profiles

ProfilePodsCPUMemoryCPU RequestMemory RequestUse case
small1024Gi12GiDevelopment namespaces, small teams
medium2048Gi24GiStandard team namespaces
large50816Gi48GiProduction namespaces, larger services
xlarge1001632Gi816GiHigh-scale production or platform namespaces

Each profile sets pods, cpu, memory, requests.cpu, requests.memory, limits.cpu, and limits.memory.


Usage

Set profile on any resourceQuotas entry:

onCreate:
  resourceQuotas:
    - name: "{{ .metadata.name }}-quota"
      profile: medium
      reconcile: true

Or dynamically from the CR spec:

resourceQuotas:
  - name: "{{ .metadata.name }}-quota"
    profile: '{{ .spec.size | default "small" }}'
    reconcile: true

This pattern is common in namespace provisioning operators where the CR carries a size field that controls how much of the cluster the namespace receives.


Rules

Profile or explicit — not both.

profile and hard cannot coexist on the same ResourceQuota entry. Orkestra ignores the profile if hard is also set and logs a warning.

# Valid
resourceQuotas:
  - name: ns-quota
    profile: large

# Valid
resourceQuotas:
  - name: ns-quota
    hard:
      pods: "30"
      cpu: "6"
      memory: 12Gi

# Invalid — profile is ignored, hard wins
resourceQuotas:
  - name: ns-quota
    profile: large
    hard:
      pods: "30"

Unknown profiles log a warning and skip the resource. A typo does not cause a reconcile failure — Orkestra skips that ResourceQuota and logs the unknown profile name.


Choosing a profile

SituationProfile
Developer sandbox, local testingsmall
Team namespace, feature environmentmedium
Production service namespacelarge
Platform or high-traffic productionxlarge
Fine-grained control neededOmit profile, use hard directly