chore: migrate PASEO_PORT to PASEO_LISTEN across codebase

This commit is contained in:
Mohamed Boudra
2026-02-05 14:35:35 +07:00
parent 7ae56bcdd1
commit 8d1d7b7603
4 changed files with 8 additions and 11 deletions
+1 -2
View File
@@ -102,7 +102,7 @@ function sleep(ms: number): Promise<void> {
* Start a test daemon programmatically using the server's bootstrap API * Start a test daemon programmatically using the server's bootstrap API
* *
* This starts the daemon in a separate process using the CLI's daemon start command * This starts the daemon in a separate process using the CLI's daemon start command
* with isolated PASEO_HOME and PASEO_PORT environment variables. * with isolated PASEO_HOME and PASEO_LISTEN environment variables.
*/ */
export async function startTestDaemon(options?: { export async function startTestDaemon(options?: {
port?: number port?: number
@@ -128,7 +128,6 @@ export async function startTestDaemon(options?: {
...process.env, ...process.env,
PASEO_HOME: paseoHome, PASEO_HOME: paseoHome,
PASEO_LISTEN: `127.0.0.1:${port}`, PASEO_LISTEN: `127.0.0.1:${port}`,
PASEO_PORT: String(port),
// Disable relay for tests // Disable relay for tests
PASEO_RELAY_ENABLED: 'false', PASEO_RELAY_ENABLED: 'false',
// Force no TTY to prevent QR code output // Force no TTY to prevent QR code output
+1 -1
View File
@@ -72,7 +72,7 @@ export async function startDaemon(
paseoHome: string paseoHome: string
): Promise<ProcessPromise> { ): Promise<ProcessPromise> {
$.verbose = false $.verbose = false
const daemon = $`PASEO_HOME=${paseoHome} PASEO_PORT=${port} paseo daemon start --foreground`.nothrow() const daemon = $`PASEO_HOME=${paseoHome} PASEO_LISTEN=127.0.0.1:${port} paseo daemon start --foreground`.nothrow()
return daemon return daemon
} }
+3 -5
View File
@@ -76,15 +76,13 @@ STT_MODEL=whisper-1 # Optional: override to gpt-4o-transcribe, etc.
STT_CONFIDENCE_THRESHOLD=-3.0 # Optional: reject low-confidence clips STT_CONFIDENCE_THRESHOLD=-3.0 # Optional: reject low-confidence clips
STT_DEBUG_AUDIO_DIR=.stt-debug # Optional: persist raw dictation audio for debugging STT_DEBUG_AUDIO_DIR=.stt-debug # Optional: persist raw dictation audio for debugging
PASEO_HOME=~/.paseo # Runtime state directory (agents/, etc.) PASEO_HOME=~/.paseo # Runtime state directory (agents/, etc.)
PASEO_PORT=6767 # Voice server + MCP port (falls back to 6767) PASEO_LISTEN=127.0.0.1:6767 # Listen address (host:port or /path/to/socket)
PORT=3000 # Server port
NODE_ENV=development # Environment
``` ```
`PASEO_HOME` defaults to `~/.paseo` and isolates runtime artifacts like `agents/`. `PASEO_PORT` takes precedence over `PORT` and controls both the HTTP server and MCP endpoint. For blue/green testing you can run a parallel server without touching production state: `PASEO_HOME` defaults to `~/.paseo` and isolates runtime artifacts like `agents/`. `PASEO_LISTEN` controls the daemon listen address. For blue/green testing you can run a parallel server without touching production state:
```bash ```bash
PASEO_HOME=~/.paseo-blue PASEO_PORT=7777 npm run dev PASEO_HOME=~/.paseo-blue PASEO_LISTEN=127.0.0.1:7777 npm run dev
``` ```
## Tech Stack ## Tech Stack
@@ -6,7 +6,7 @@
* npx tsx packages/server/src/server/daemon-e2e/checkout-debug.ts [agentIdOrCwd1] [agentIdOrCwd2] * npx tsx packages/server/src/server/daemon-e2e/checkout-debug.ts [agentIdOrCwd1] [agentIdOrCwd2]
* *
* To test against a different daemon: * To test against a different daemon:
* PASEO_PORT=7777 npx tsx packages/server/src/server/daemon-e2e/checkout-debug.ts * PASEO_LISTEN=127.0.0.1:7777 npx tsx packages/server/src/server/daemon-e2e/checkout-debug.ts
*/ */
import { WebSocket } from "ws"; import { WebSocket } from "ws";
@@ -30,8 +30,8 @@ class LoggingWebSocket extends OriginalWebSocket {
} }
const PASEO_HOME = process.env.PASEO_HOME ?? `${os.homedir()}/.paseo`; const PASEO_HOME = process.env.PASEO_HOME ?? `${os.homedir()}/.paseo`;
const PASEO_PORT = process.env.PASEO_PORT ?? "6767"; const PASEO_LISTEN = process.env.PASEO_LISTEN ?? "127.0.0.1:6767";
const DAEMON_URL = `ws://127.0.0.1:${PASEO_PORT}/ws`; const DAEMON_URL = `ws://${PASEO_LISTEN}/ws`;
async function testMultiAgentSequence() { async function testMultiAgentSequence() {
console.log("\n=== Testing multi-agent checkout sequence ==="); console.log("\n=== Testing multi-agent checkout sequence ===");