From 42f55855ebb1e6fb36f0f24c553de4ba6f9244b3 Mon Sep 17 00:00:00 2001 From: Thomas Hallock Date: Wed, 21 Jan 2026 14:38:30 -0600 Subject: [PATCH] fix(litefs): remove HOSTNAME env var to allow pod hostname detection LiteFS needs the actual pod hostname for cluster communication, but HOSTNAME=0.0.0.0 was being set in both the Dockerfile and ConfigMap, overriding the pod's hostname. Co-Authored-By: Claude Opus 4.5 --- Dockerfile | 2 +- infra/terraform/app.tf | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index f6cb87e4..47754da9 100644 --- a/Dockerfile +++ b/Dockerfile @@ -199,7 +199,7 @@ EXPOSE 3000 # LiteFS proxy listens on 8080, app on 3000 EXPOSE 8080 ENV PORT=3000 -ENV HOSTNAME="0.0.0.0" +# Note: Don't set HOSTNAME here - LiteFS needs the pod's actual hostname ENV NODE_ENV=production # Default: run without LiteFS (for local dev and Docker Compose) diff --git a/infra/terraform/app.tf b/infra/terraform/app.tf index 84c2806d..1d122569 100644 --- a/infra/terraform/app.tf +++ b/infra/terraform/app.tf @@ -27,7 +27,8 @@ resource "kubernetes_config_map" "app_config" { data = { NODE_ENV = "production" PORT = "3000" - HOSTNAME = "0.0.0.0" + # Note: Don't set HOSTNAME here - it conflicts with LiteFS which needs the pod hostname + # Next.js will use 0.0.0.0 by default if HOSTNAME is not set NEXT_TELEMETRY_DISABLED = "1" REDIS_URL = "redis://redis:6379" # LiteFS mounts the database at /litefs