From 4558688bafbb651d26a282748f0f5b44412e675c Mon Sep 17 00:00:00 2001 From: Viktor Barzin Date: Sun, 1 Mar 2026 17:41:18 +0000 Subject: [PATCH] [ci skip] nextcloud: bump CPU limit to 16, add custom ResourceQuota CPU was pegged at 2000m/2000m (100% throttled). Add custom-quota opt-out label and ResourceQuota allowing 32 CPU limits to accommodate the 16 CPU container limit plus sidecar defaults. --- stacks/nextcloud/chart_values.yaml | 2 +- stacks/nextcloud/main.tf | 19 ++++++++++++++++++- 2 files changed, 19 insertions(+), 2 deletions(-) diff --git a/stacks/nextcloud/chart_values.yaml b/stacks/nextcloud/chart_values.yaml index 458a2b0b..b7be14fb 100644 --- a/stacks/nextcloud/chart_values.yaml +++ b/stacks/nextcloud/chart_values.yaml @@ -63,7 +63,7 @@ collabora: resources: limits: - cpu: "2" + cpu: "16" memory: 6Gi requests: cpu: 100m diff --git a/stacks/nextcloud/main.tf b/stacks/nextcloud/main.tf index 4aec6687..84970260 100644 --- a/stacks/nextcloud/main.tf +++ b/stacks/nextcloud/main.tf @@ -18,6 +18,23 @@ resource "kubernetes_namespace" "nextcloud" { "istio-injection" : "disabled" tier = local.tiers.edge "resource-governance/custom-limitrange" = "true" + "resource-governance/custom-quota" = "true" + } + } +} + +resource "kubernetes_resource_quota" "nextcloud" { + metadata { + name = "nextcloud-quota" + namespace = kubernetes_namespace.nextcloud.metadata[0].name + } + spec { + hard = { + "requests.cpu" = "4" + "requests.memory" = "8Gi" + "limits.cpu" = "32" + "limits.memory" = "16Gi" + pods = "10" } } } @@ -39,7 +56,7 @@ resource "kubernetes_limit_range" "nextcloud" { memory = "64Mi" } max = { - cpu = "4" + cpu = "16" memory = "8Gi" } }