fix: remove duplicate PID lock and simplify socket path config

- Remove duplicate acquirePidLock call from bootstrap.ts (keep in index.ts
  where proper error handling exists)
- Remove PASEO_SELF_ID_MCP_SOCK env var override from config.ts
This commit is contained in:
Mohamed Boudra
2026-01-30 11:54:15 +07:00
parent 1670c7084b
commit 829de66d2f
2 changed files with 3 additions and 11 deletions
+2 -7
View File
@@ -15,12 +15,7 @@ function getDefaultListen(): string {
return `127.0.0.1:${DEFAULT_PORT}`;
}
function getSelfIdMcpSocketPath(paseoHome: string, env: NodeJS.ProcessEnv): string {
// Allow override via PASEO_SELF_ID_MCP_SOCK for testing
if (env.PASEO_SELF_ID_MCP_SOCK) {
return env.PASEO_SELF_ID_MCP_SOCK;
}
// Default to ${PASEO_HOME}/self-id-mcp.sock
function getSelfIdMcpSocketPath(paseoHome: string): string {
return path.join(paseoHome, "self-id-mcp.sock");
}
@@ -87,7 +82,7 @@ export function loadConfig(
// Default is TCP at 127.0.0.1:6767
const listen = env.PASEO_LISTEN ?? persisted.listen ?? getDefaultListen();
const mcpListen = getListenForMcp(listen);
const selfIdMcpSocketPath = getSelfIdMcpSocketPath(paseoHome, env);
const selfIdMcpSocketPath = getSelfIdMcpSocketPath(paseoHome);
const envCorsOrigins = env.PASEO_CORS_ORIGINS
? env.PASEO_CORS_ORIGINS.split(",").map((s) => s.trim())