From bf39de591c98b2494ef4495dc7c563c658144dad Mon Sep 17 00:00:00 2001 From: Ojus Save Date: Mon, 26 Jan 2026 01:51:23 -0800 Subject: [PATCH] debug: verify config is readable and disable cache --- scripts/render-start.sh | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/scripts/render-start.sh b/scripts/render-start.sh index 145efa171..69f094777 100755 --- a/scripts/render-start.sh +++ b/scripts/render-start.sh @@ -50,9 +50,29 @@ ls -la "${HOME_CONFIG_DIR}/" # Start the gateway with token from env var # Explicitly set CLAWDBOT_CONFIG_PATH to ensure config is loaded from the file we wrote +# Disable config cache to ensure fresh reads echo "=== Starting gateway with CLAWDBOT_STATE_DIR=${CLAWDBOT_STATE_DIR} ===" echo "=== Setting CLAWDBOT_CONFIG_PATH=${CONFIG_FILE} ===" +echo "=== Disabling config cache ===" export CLAWDBOT_CONFIG_PATH="${CONFIG_FILE}" +export CLAWDBOT_CONFIG_CACHE_MS=0 + +# Verify config can be read +echo "=== Verifying config can be read ===" +node -e " +const fs = require('fs'); +const path = '${CONFIG_FILE}'; +if (fs.existsSync(path)) { + const content = fs.readFileSync(path, 'utf-8'); + const parsed = JSON.parse(content); + console.log('Config loaded successfully:'); + console.log('trustedProxies:', JSON.stringify(parsed.gateway?.trustedProxies)); +} else { + console.error('Config file not found:', path); + process.exit(1); +} +" + exec node dist/index.js gateway \ --port 8080 \ --bind lan \