fix: run cli core probes via frontend container

This commit is contained in:
Codex
2026-05-18 03:45:29 +00:00
parent c514b6ca9e
commit 54c32be901
4 changed files with 14 additions and 12 deletions
+4 -2
View File
@@ -662,7 +662,7 @@ function brokerSource(): string {
return String.raw`
const open = JSON.parse(process.argv[2] || process.argv[1] || "{}");
const token = process.env.PROVIDER_TOKEN || "";
const url = "ws://127.0.0.1:8080/ws/ssh?token=" + encodeURIComponent(token);
const url = "ws://backend-core:8080/ws/ssh?token=" + encodeURIComponent(token);
const ws = new WebSocket(url);
let exitCode = 255;
let canSend = false;
@@ -805,7 +805,9 @@ export async function runSsh(config: UniDeskConfig, providerId: string, args: st
const child = spawn("docker", [
"exec",
"-i",
"unidesk-backend-core",
"-e",
`PROVIDER_TOKEN=${config.providerGateway.token}`,
"unidesk-frontend",
"bun",
"-e",
brokerSource(),