mirror of
https://github.com/johndoe6345789/docker-swarm-termina.git
synced 2026-04-24 13:45:01 +00:00
Changed Socket.IO transport order from ['websocket', 'polling'] to ['polling', 'websocket'] in the frontend terminal hook. Why this fixes the issue: - Cloudflare blocks direct WebSocket connections with 400 Bad Request - HTTP polling works perfectly and bypasses Cloudflare's WebSocket protection - Socket.IO now connects via polling first, then attempts upgrade to WebSocket - If WebSocket upgrade fails (due to Cloudflare), connection stays on polling - This ensures reliable connectivity without requiring Cloudflare config changes Testing script included demonstrates: ✓ Polling transport: WORKS ✗ Direct WebSocket: BLOCKED by Cloudflare ✓ Auto-upgrade (polling→websocket): WORKS with graceful fallback https://claude.ai/code/session_01SePwA78FSw4urCoyR2cqFh
4.5 KiB
4.5 KiB