Somrat Sorkar commited on
Commit
8f0d1fd
Β·
1 Parent(s): 1fc658a

Add gateway logging and startup verification

Browse files
Files changed (1) hide show
  1. start.sh +11 -1
start.sh CHANGED
@@ -247,8 +247,18 @@ node /home/node/app/health-server.js &
247
  # ── Launch gateway ──
248
  echo "πŸš€ Launching OpenClaw gateway on port 7860..."
249
  echo ""
250
- openclaw gateway run --port 7860 --bind lan --verbose &
251
  GATEWAY_PID=$!
252
 
 
 
 
 
 
 
 
 
 
 
253
  # Wait for gateway (allows trap to fire)
254
  wait $GATEWAY_PID
 
247
  # ── Launch gateway ──
248
  echo "πŸš€ Launching OpenClaw gateway on port 7860..."
249
  echo ""
250
+ openclaw gateway run --port 7860 --bind lan --verbose 2>&1 | tee -a /home/node/.openclaw/gateway.log &
251
  GATEWAY_PID=$!
252
 
253
+ # Wait a moment for startup errors
254
+ sleep 3
255
+ if ! kill -0 $GATEWAY_PID 2>/dev/null; then
256
+ echo ""
257
+ echo "❌ Gateway failed to start. Last 30 lines of log:"
258
+ echo "────────────────────────────────────────────"
259
+ tail -30 /home/node/.openclaw/gateway.log
260
+ exit 1
261
+ fi
262
+
263
  # Wait for gateway (allows trap to fire)
264
  wait $GATEWAY_PID