diff --git a/.github/workflows/publish_extra.yml b/.github/workflows/publish_extra.yml index 6775696770..30f22e7933 100644 --- a/.github/workflows/publish_extra.yml +++ b/.github/workflows/publish_extra.yml @@ -50,10 +50,11 @@ jobs: - name: Start container run: | docker run -d --name windmill-extra-test \ - -p 3001:3001 -p 3002:3002 -p 5679:5679 \ + -p 3001:3001 -p 3002:3002 -p 3003:3003 \ -e ENABLE_LSP=true \ -e ENABLE_MULTIPLAYER=true \ -e ENABLE_DEBUGGER=true \ + -e DEBUGGER_PORT=3003 \ -e REQUIRE_SIGNED_DEBUG_REQUESTS=false \ windmill-extra:test diff --git a/Caddyfile b/Caddyfile index 947e0522cb..4b330de42f 100644 --- a/Caddyfile +++ b/Caddyfile @@ -18,10 +18,10 @@ # Uncomment and set ENABLE_MULTIPLAYER=true in docker-compose.yml # reverse_proxy /ws_mp/* http://windmill_extra:3002 - # Debugger - Interactive debugging via DAP WebSocket (windmill_extra:5679) + # Debugger - Interactive debugging via DAP WebSocket (windmill_extra:3003) # Set ENABLE_DEBUGGER=true in docker-compose.yml to enable handle_path /ws_debug/* { - reverse_proxy http://windmill_extra:5679 + reverse_proxy http://windmill_extra:3003 } # Search indexer, Enterprise Edition (windmill_indexer:8002) diff --git a/debugger/README.md b/debugger/README.md index 3caed251aa..dbeb213351 100644 --- a/debugger/README.md +++ b/debugger/README.md @@ -49,7 +49,7 @@ bun run debug/dap_debug_service.ts ``` Options: -- `--port PORT` - Server port (default: 5679) +- `--port PORT` - Server port (default: 3003) - `--host HOST` - Server host (default: 0.0.0.0) - `--python-path PATH` - Python binary path (default: python3) - `--bun-path PATH` - Bun binary path (default: bun) @@ -67,7 +67,7 @@ Options: | Variable | Description | Default | |----------|-------------|---------| -| `DAP_PORT` | Server port | 5679 | +| `DAP_PORT` | Server port | 3003 | | `DAP_HOST` | Server host | 0.0.0.0 | | `DAP_PYTHON_PATH` | Python binary path | python3 | | `DAP_BUN_PATH` | Bun binary path | bun | diff --git a/debugger/dap_debug_service.ts b/debugger/dap_debug_service.ts index 024c7beeee..e9dcc68c3c 100644 --- a/debugger/dap_debug_service.ts +++ b/debugger/dap_debug_service.ts @@ -16,7 +16,7 @@ * bun run dap_debug_service.ts [options] * * Options: - * --port PORT Server port (default: 5679) + * --port PORT Server port (default: 3003) * --host HOST Server host (default: 0.0.0.0) * --nsjail Enable nsjail wrapping * --nsjail-config PATH Path to nsjail config file @@ -68,7 +68,7 @@ interface ServiceConfig { function parseConfig(): ServiceConfig { const args = process.argv.slice(2) const config: ServiceConfig = { - port: parseInt(process.env.DAP_PORT || '5679', 10), + port: parseInt(process.env.DAP_PORT || '3003', 10), host: process.env.DAP_HOST || '0.0.0.0', nsjail: { enabled: process.env.DAP_NSJAIL_ENABLED === 'true', diff --git a/debugger/test_debug_service.ts b/debugger/test_debug_service.ts index e9cebaa964..de01779f3c 100644 --- a/debugger/test_debug_service.ts +++ b/debugger/test_debug_service.ts @@ -21,7 +21,7 @@ import { spawn } from 'bun' -const SERVICE_URL = 'ws://localhost:5679' +const SERVICE_URL = 'ws://localhost:3003' const TEST_NSJAIL = process.argv.includes('--nsjail') const TEST_AUTOINSTALL = process.argv.includes('--test-autoinstall') @@ -810,7 +810,7 @@ async function testHealthEndpoint(): Promise { console.log('\n=== Testing Health Endpoint ===') try { - const response = await fetch(`http://localhost:5679/health`) + const response = await fetch(`http://localhost:3003/health`) const data = await response.json() console.log(` Health response: ${JSON.stringify(data)}`) diff --git a/docker-compose.yml b/docker-compose.yml index b5c7abcedd..52f6e26185 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -180,11 +180,12 @@ services: expose: - 3001 # LSP - 3002 # Multiplayer - - 5679 # Debugger + - 3003 # Debugger environment: - ENABLE_LSP=true - ENABLE_MULTIPLAYER=false # Set to true to enable multiplayer (Enterprise Edition) - ENABLE_DEBUGGER=true # Set to true to enable debugger + - DEBUGGER_PORT=3003 # Debugger service port - ENABLE_NSJAIL=false # Set to true for nsjail sandboxing (requires privileged: true) - REQUIRE_SIGNED_DEBUG_REQUESTS=false # Set to true to require JWT tokens for debug sessions - WINDMILL_BASE_URL=http://windmill_server:8000 diff --git a/docker/entrypoint-extra.sh b/docker/entrypoint-extra.sh index 009559711b..c0f342254a 100644 --- a/docker/entrypoint-extra.sh +++ b/docker/entrypoint-extra.sh @@ -64,11 +64,11 @@ fi # Start Debugger service if [ "${ENABLE_DEBUGGER:-true}" = "true" ]; then - echo "[entrypoint] Starting Debugger on port ${DEBUGGER_PORT:-5679}..." + echo "[entrypoint] Starting Debugger on port ${DEBUGGER_PORT:-3003}..." cd /debugger # Build debugger arguments - DEBUGGER_ARGS="--host ${HOST:-0.0.0.0} --port ${DEBUGGER_PORT:-5679}" + DEBUGGER_ARGS="--host ${HOST:-0.0.0.0} --port ${DEBUGGER_PORT:-3003}" DEBUGGER_ARGS="$DEBUGGER_ARGS --windmill /usr/local/bin/windmill" # Enable nsjail if requested diff --git a/docker/test_windmill_extra.ts b/docker/test_windmill_extra.ts index 25b7916598..46ffce54c9 100644 --- a/docker/test_windmill_extra.ts +++ b/docker/test_windmill_extra.ts @@ -5,20 +5,20 @@ * Tests all three services: * - LSP (Language Server Protocol) - Port 3001 * - Multiplayer (y-websocket) - Port 3002 - * - Debugger (DAP WebSocket) - Port 5679 + * - Debugger (DAP WebSocket) - Port 3003 * * Configuration via environment variables: * - WINDMILL_EXTRA_HOST: Container hostname (default: localhost) * - LSP_PORT: LSP service port (default: 3001) * - MULTIPLAYER_PORT: Multiplayer service port (default: 3002) - * - DEBUGGER_PORT: Debugger service port (default: 5679) + * - DEBUGGER_PORT: Debugger service port (default: 3003) * - SKIP_LSP: Skip LSP tests (default: false) * - SKIP_MULTIPLAYER: Skip Multiplayer tests (default: false) * - SKIP_DEBUGGER: Skip Debugger tests (default: false) * * Usage: * # Start the container first - * docker run -p 3001:3001 -p 3002:3002 -p 5679:5679 \ + * docker run -p 3001:3001 -p 3002:3002 -p 3003:3003 \ * -e ENABLE_LSP=true -e ENABLE_MULTIPLAYER=true -e ENABLE_DEBUGGER=true \ * windmill-extra * @@ -33,7 +33,7 @@ const HOST = process.env.WINDMILL_EXTRA_HOST || 'localhost' const LSP_PORT = parseInt(process.env.LSP_PORT || '3001') const MULTIPLAYER_PORT = parseInt(process.env.MULTIPLAYER_PORT || '3002') -const DEBUGGER_PORT = parseInt(process.env.DEBUGGER_PORT || '5679') +const DEBUGGER_PORT = parseInt(process.env.DEBUGGER_PORT || '3003') const SKIP_LSP = process.env.SKIP_LSP === 'true' const SKIP_MULTIPLAYER = process.env.SKIP_MULTIPLAYER === 'true' const SKIP_DEBUGGER = process.env.SKIP_DEBUGGER === 'true' @@ -616,7 +616,7 @@ async function main() { } catch (error) { console.error(`\n✗ ${error instanceof Error ? error.message : error}`) console.error('\nMake sure the windmill-extra container is running:') - console.error(' docker run -p 3001:3001 -p 3002:3002 -p 5679:5679 \\') + console.error(' docker run -p 3001:3001 -p 3002:3002 -p 3003:3003 \\') console.error(' -e ENABLE_LSP=true -e ENABLE_MULTIPLAYER=true -e ENABLE_DEBUGGER=true \\') console.error(' windmill-extra') process.exit(1) diff --git a/frontend/src/lib/components/debug/dapClient.ts b/frontend/src/lib/components/debug/dapClient.ts index 8e2dd5b5d1..71783b4ec0 100644 --- a/frontend/src/lib/components/debug/dapClient.ts +++ b/frontend/src/lib/components/debug/dapClient.ts @@ -91,7 +91,7 @@ export class DAPClient { > = new Map() private url: string - constructor(url: string = 'ws://localhost:5679') { + constructor(url: string = 'ws://localhost:3003') { this.url = url } diff --git a/frontend/src/lib/components/debug/index.ts b/frontend/src/lib/components/debug/index.ts index e7226a39ed..a853a718a1 100644 --- a/frontend/src/lib/components/debug/index.ts +++ b/frontend/src/lib/components/debug/index.ts @@ -34,7 +34,7 @@ * * ``` @@ -94,7 +94,7 @@ export function getDebugServerUrl(language: DebugLanguage): string { const path = DAP_ENDPOINT_PATHS[language] || DAP_ENDPOINT_PATHS.python3 if (typeof window === 'undefined') { // SSR fallback - return `ws://localhost:5679${path}` + return `ws://localhost:3003${path}` } const wsProtocol = window.location.protocol === 'https:' ? 'wss' : 'ws' return `${wsProtocol}://${window.location.host}/ws_debug${path}`