From 02985d0e9117d8f3e2ebd60ad9075f8913543e8d Mon Sep 17 00:00:00 2001 From: Fabian Wiesel Date: Thu, 18 Jun 2026 16:58:22 +0200 Subject: [PATCH] Set GOMEMLIMIT from container memory limit Without GOMEMLIMIT the Go GC is unaware of the container limit and may let the heap grow until the kernel OOM-kills the process. --- .../openstack-hypervisor-operator/templates/deployment.yaml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/charts/openstack-hypervisor-operator/templates/deployment.yaml b/charts/openstack-hypervisor-operator/templates/deployment.yaml index b37cfca1..5739a3f5 100644 --- a/charts/openstack-hypervisor-operator/templates/deployment.yaml +++ b/charts/openstack-hypervisor-operator/templates/deployment.yaml @@ -47,6 +47,11 @@ spec: value: {{ quote .Values.controllerManager.manager.env.labelSelector }} - name: KUBERNETES_CLUSTER_DOMAIN value: {{ quote .Values.kubernetesClusterDomain }} + - name: GOMEMLIMIT + valueFrom: + resourceFieldRef: + resource: limits.memory + divisor: "1" image: {{ .Values.controllerManager.manager.image.repository }}:{{ .Chart.AppVersion }} livenessProbe: httpGet: