From 40959de0a20864864fc14cd461c6afcddcaa7a10 Mon Sep 17 00:00:00 2001 From: Daniel Santillan Date: Mon, 21 Sep 2026 15:24:28 -0400 Subject: [PATCH] Forward the COACH_* variables to the api container in the deploy compose MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The api service lists its environment explicitly, and that list is an allowlist: a variable set in the host's .env reaches the container only when it is named there. Everything else in the panel is used solely to substitute ${…} in the compose file — which is how COACH_PROVIDER can sit in Dokploy looking applied while the api never sees it, the Coach stays off, and no screen anywhere shows a button. That is exactly what happened on this instance. The `:-` defaults keep an instance that sets none of them byte-for-byte as it was: an empty value reads as unset in coach/config.js. --- deploy/compose-build-at-deploy.yml | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/deploy/compose-build-at-deploy.yml b/deploy/compose-build-at-deploy.yml index e943e4f..e734d88 100644 --- a/deploy/compose-build-at-deploy.yml +++ b/deploy/compose-build-at-deploy.yml @@ -82,6 +82,17 @@ services: RP_ID: ${RP_ID} RP_NAME: ${RP_NAME} ORIGIN: ${ORIGIN} + # This list is an allowlist: a variable set in the host's .env reaches the container ONLY + # if it is named here. Host env vars are otherwise used just to substitute ${…} in this + # file, so `COACH_PROVIDER` sitting in the panel while the container never sees it is a + # configuration that looks applied and does nothing. The `:-` defaults are what keep an + # instance that sets none of them exactly as it was: an empty value reads as unset. + COACH_PROVIDER: ${COACH_PROVIDER:-} + COACH_BASE_URL: ${COACH_BASE_URL:-} + COACH_MODEL: ${COACH_MODEL:-} + COACH_API_KEY: ${COACH_API_KEY:-} + COACH_DISABLED: ${COACH_DISABLED:-} + COACH_JOB_TIMEOUT_MS: ${COACH_JOB_TIMEOUT_MS:-} command: - /bin/sh - -c