From 81929cc428e8b3de5d84da2556e4a3999f50a857 Mon Sep 17 00:00:00 2001 From: AdaAibaby Date: Wed, 1 Jul 2026 13:50:46 +0800 Subject: [PATCH 1/3] fix: align client-proxy HEALTH_PORT default to 3001 The binary default for HEALTH_PORT was 3003, but the Nomad IaC module (job-client-proxy/variables.tf) and GCP provider (variables.tf) both default to 3001. In Nomad deployments HEALTH_PORT is set from NOMAD_PORT_health so the mismatch is masked, but self-hosted or standalone deployments using the binary default would listen on the wrong port. Align the Go envDefault to 3001 to match the IaC defaults. Fixes #3052 --- packages/client-proxy/internal/cfg/model.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/client-proxy/internal/cfg/model.go b/packages/client-proxy/internal/cfg/model.go index e43f984966..df25c522bc 100644 --- a/packages/client-proxy/internal/cfg/model.go +++ b/packages/client-proxy/internal/cfg/model.go @@ -3,7 +3,7 @@ package cfg import "github.com/caarlos0/env/v11" type Config struct { - HealthPort uint16 `env:"HEALTH_PORT" envDefault:"3003"` + HealthPort uint16 `env:"HEALTH_PORT" envDefault:"3001"` ProxyPort uint16 `env:"PROXY_PORT" envDefault:"3002"` RedisURL string `env:"REDIS_URL"` From f982e1c64c038a2399323c05e10c399a4f8c564a Mon Sep 17 00:00:00 2001 From: AdaAibaby Date: Wed, 1 Jul 2026 13:55:11 +0800 Subject: [PATCH 2/3] test: update TestParse_Defaults to expect health port 3001 --- packages/client-proxy/internal/cfg/model_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/client-proxy/internal/cfg/model_test.go b/packages/client-proxy/internal/cfg/model_test.go index 38d61d4fa4..2a5105e157 100644 --- a/packages/client-proxy/internal/cfg/model_test.go +++ b/packages/client-proxy/internal/cfg/model_test.go @@ -21,7 +21,7 @@ func TestParse_Defaults(t *testing.T) { cfg, err := Parse() require.NoError(t, err) - require.EqualValues(t, 3003, cfg.HealthPort) + require.EqualValues(t, 3001, cfg.HealthPort) require.EqualValues(t, 3002, cfg.ProxyPort) require.Equal(t, 40, cfg.RedisPoolSize) require.Empty(t, cfg.RedisURL) From a19e6913b7b99dc8bbea5cdcaa977c26e25c8480 Mon Sep 17 00:00:00 2001 From: AdaAibaby Date: Wed, 1 Jul 2026 13:58:32 +0800 Subject: [PATCH 3/3] fix: update hardcoded health port 3003 references to 3001 Update CI start-services action and DEV-LOCAL.md to use port 3001, matching the new binary default. --- .github/actions/start-services/action.yml | 2 +- DEV-LOCAL.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/actions/start-services/action.yml b/.github/actions/start-services/action.yml index 5e57f3033b..6c128f0fee 100644 --- a/.github/actions/start-services/action.yml +++ b/.github/actions/start-services/action.yml @@ -157,5 +157,5 @@ runs: STARTUP_TIMEOUT=60 ./scripts/start-service.sh "API" packages/api run ~/logs/api.log http://localhost:3000/health # Start client-proxy (needed for auto-resume tests) - ./scripts/start-service.sh "ClientProxy" packages/client-proxy run ~/logs/client-proxy.log http://localhost:3003 + ./scripts/start-service.sh "ClientProxy" packages/client-proxy run ~/logs/client-proxy.log http://localhost:3001 shell: bash diff --git a/DEV-LOCAL.md b/DEV-LOCAL.md index a72afafbbd..0546bb9546 100644 --- a/DEV-LOCAL.md +++ b/DEV-LOCAL.md @@ -128,7 +128,7 @@ These commands launch each service in the foreground. You need multiple terminal ```bash make -C packages/client-proxy run-local ``` - Verify: `curl -s http://localhost:3003/health` returns a response. + Verify: `curl -s http://localhost:3001/health` returns a response. ## Build the base template