From 0da6f90ad21a5c99e256cc2f155db735e64b125d Mon Sep 17 00:00:00 2001 From: Viktor Barzin Date: Sun, 1 Mar 2026 14:44:22 +0000 Subject: [PATCH] =?UTF-8?q?[ci=20skip]=20openclaw:=20fix=20slow=20startup?= =?UTF-8?q?=20=E2=80=94=20proper=20resources=20+=20readiness=20probe=20+?= =?UTF-8?q?=20VPA=20off?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Set explicit CPU (2 cores) and memory (2Gi) limits Root cause: Goldilocks VPA was throttling to 300m CPU, causing gateway to take 5+ minutes to start, and 1Gi memory caused OOM crashes - Add TCP readiness probe on port 18789 to prevent 502 Bad Gateway during startup (Traefik was routing before gateway was listening) - Disable Goldilocks VPA via namespace label (vpa-update-mode: off) --- stacks/openclaw/main.tf | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/stacks/openclaw/main.tf b/stacks/openclaw/main.tf index edcd500e..47d80b6e 100644 --- a/stacks/openclaw/main.tf +++ b/stacks/openclaw/main.tf @@ -13,7 +13,8 @@ resource "kubernetes_namespace" "openclaw" { metadata { name = "openclaw" labels = { - tier = local.tiers.aux + tier = local.tiers.aux + "goldilocks.fairwinds.com/vpa-update-mode" = "off" } } } @@ -358,6 +359,13 @@ resource "kubernetes_deployment" "openclaw" { port { container_port = 18789 } + readiness_probe { + tcp_socket { + port = 18789 + } + initial_delay_seconds = 30 + period_seconds = 10 + } env { name = "OPENCLAW_GATEWAY_TOKEN" value = random_password.gateway_token.result @@ -432,10 +440,12 @@ resource "kubernetes_deployment" "openclaw" { } resources { limits = { - memory = "1Gi" + cpu = "2" + memory = "2Gi" } requests = { - memory = "64Mi" + cpu = "100m" + memory = "512Mi" } } }