@beeos-ai/cli 1.0.20 → 1.0.21
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +23 -2
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -2051,13 +2051,34 @@ var init_vnc_bridge = __esm({
|
|
|
2051
2051
|
* Build the environment map used when launching vnc-bridge for a
|
|
2052
2052
|
* device. Exposed separately so the service target-spec builder
|
|
2053
2053
|
* can reuse the same logic without duplicating it.
|
|
2054
|
+
*
|
|
2055
|
+
* Env-var names are aligned with the **vnc-bridge 0.3.6** clap
|
|
2056
|
+
* definitions (`devices/vnc-bridge/src/main.rs`):
|
|
2057
|
+
*
|
|
2058
|
+
* --vnc env: VNC_ADDR=host:port (combined, NOT VNC_HOST/VNC_PORT)
|
|
2059
|
+
* --gateway env: AGENT_GATEWAY_URL
|
|
2060
|
+
* --key-file env: AGENT_KEY_FILE (single combined key, NOT BRIDGE_PRIVATE/PUBLIC)
|
|
2061
|
+
* --mqtt env: MQTT_BROKER_URL (static mode only)
|
|
2062
|
+
* --topic env: DEVICE_TOPIC (static mode only)
|
|
2063
|
+
*
|
|
2064
|
+
* Pre-1.0.21 we shipped the older naming (VNC_HOST + VNC_PORT,
|
|
2065
|
+
* BRIDGE_PRIVATE_KEY_FILE etc.) which the binary silently ignored,
|
|
2066
|
+
* causing it to bail out with `Error: Either --gateway + --key-file
|
|
2067
|
+
* (bootstrap mode) or --mqtt + --topic (static mode) is required`
|
|
2068
|
+
* at every restart. The legacy fields are retained alongside the
|
|
2069
|
+
* new ones so any older Rust build that did read them still works.
|
|
2054
2070
|
*/
|
|
2055
2071
|
buildEnv(opts) {
|
|
2072
|
+
const vncPort = opts.vncPort ?? 5900;
|
|
2056
2073
|
return {
|
|
2074
|
+
// ── vnc-bridge 0.3.6 canonical env vars ────────────────
|
|
2075
|
+
VNC_ADDR: `${opts.vncHost}:${vncPort}`,
|
|
2076
|
+
AGENT_GATEWAY_URL: opts.agentGatewayUrl,
|
|
2077
|
+
AGENT_KEY_FILE: opts.bridgePrivateKeyFile,
|
|
2078
|
+
// ── Legacy names (pre-0.3.6 / future-compat / forensic) ─
|
|
2057
2079
|
DEVICE_ID: opts.deviceId,
|
|
2058
2080
|
VNC_HOST: opts.vncHost,
|
|
2059
|
-
VNC_PORT: String(
|
|
2060
|
-
AGENT_GATEWAY_URL: opts.agentGatewayUrl,
|
|
2081
|
+
VNC_PORT: String(vncPort),
|
|
2061
2082
|
BRIDGE_PRIVATE_KEY_FILE: opts.bridgePrivateKeyFile,
|
|
2062
2083
|
BRIDGE_PUBLIC_KEY_FILE: opts.bridgePublicKeyFile,
|
|
2063
2084
|
LOG_FORMAT: "json",
|