Hi, when namespacing is {project}-{domain} is ther...
# ask-the-community
d
Hi, when namespacing is {project}-{domain} is there any way to set the resourcequotas based on {project}-{domain} combinations?
Current configuration: Namespacing setting:
Copy code
configmap:
    namespace_config:
      namespace_mapping:
        template: "{{ project }}-{{ domain }}"
Cluster resource manager template:
Copy code
- key: ab_project_resource_quota
        value: |
          apiVersion: v1
          kind: ResourceQuota
          metadata:
            name: project-quota
            namespace: {{ namespace }}
          spec:
            hard:
              limits.cpu: {{ projectQuotaCpu }}
              limits.memory: {{ projectQuotaMemory }}
projectQuotaCpu/ProjectQuotaMemory
Copy code
customData:
          - production:
              - projectQuotaCpu:
                  value: "400"
              - projectQuotaMemory:
                  value: "1600Gi"
not to be confused with the task resources section above
d
oh interesting, so I can configure any key value pair under
cluster_resource
here ?
do you have an example of how to set up resourceQuotas for specific {project}-{domain} combinations, and then for the rest default to
projectQuotaCpu
and
projectQuotaMemory
?
y
if you set the matchable attribute for that project/domain, it should just work
for that one it should override, for the others it should fall back to the default
d
got it, thanks so much @Yee 🙂
150 Views