@beeos-ai/cli 1.0.9 → 1.0.10

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 CHANGED
@@ -119,11 +119,26 @@ async function loadOrCreateConfig() {
119
119
  const raw = await p.readFile(path10);
120
120
  const parsed = TOML.parse(raw);
121
121
  const cfg2 = mergeWithDefaults(parsed);
122
- return cfg2;
122
+ return applyEnvOverrides(cfg2);
123
123
  }
124
124
  const cfg = defaultConfig();
125
125
  await saveConfig(cfg);
126
- return cfg;
126
+ return applyEnvOverrides(cfg);
127
+ }
128
+ function applyEnvOverrides(cfg) {
129
+ const env = globalThis.process?.env ?? {};
130
+ const apiUrl = env.BEEOS_API_URL?.trim();
131
+ const agwUrl = env.BEEOS_AGENT_GATEWAY_URL?.trim();
132
+ const dashUrl = env.BEEOS_DASHBOARD_URL?.trim();
133
+ return {
134
+ ...cfg,
135
+ platform: {
136
+ ...cfg.platform,
137
+ ...apiUrl ? { api_url: apiUrl } : {},
138
+ ...agwUrl ? { agent_gateway_url: agwUrl } : {},
139
+ ...dashUrl ? { dashboard_base_url: dashUrl } : {}
140
+ }
141
+ };
127
142
  }
128
143
  async function saveConfig(cfg) {
129
144
  const p = getPlatformAdapter();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@beeos-ai/cli",
3
- "version": "1.0.9",
3
+ "version": "1.0.10",
4
4
  "type": "module",
5
5
  "description": "BeeOS CLI — run AI agents from your desktop",
6
6
  "bin": {
@@ -9,6 +9,22 @@
9
9
  `-Device` is passed. Heavier deps (Python, uv, adb, scrcpy/vnc bridges)
10
10
  are installed lazily by the CLI itself.
11
11
 
12
+ Staging / dev-loop env vars (CLI >= 1.0.10). All four are inherited by
13
+ the spawned `beeos init` / `beeos device attach` child via the normal
14
+ process env passthrough — no extra Set-Item / -PassThru is needed. CLI
15
+ >= 1.0.10 reads them via the loadOrCreateConfig env-overrides layer;
16
+ older CLIs only honor BEEOS_API_URL (telemetry) +
17
+ BEEOS_AGENT_GATEWAY_URL (runtime).
18
+
19
+ $env:BEEOS_API_URL Public API base; both this script
20
+ (telemetry) and the CLI runtime use
21
+ this.
22
+ $env:BEEOS_AGENT_GATEWAY_URL Agent Gateway base (Ed25519-signed
23
+ bootstrap requests).
24
+ $env:BEEOS_DASHBOARD_URL Dashboard base (OAuth + bind redirect).
25
+ $env:BEEOS_DEVICE_AGENT_VERSION Pin @beeos-ai/device-agent semver.
26
+ $env:BEEOS_MCP_SERVER_VERSION Pin @beeos-ai/device-mcp-server semver.
27
+
12
28
  .EXAMPLE
13
29
  # One-liner (PowerShell 5+):
14
30
  irm https://beeos.ai/install.ps1 | iex
@@ -20,6 +36,15 @@
20
36
  .EXAMPLE
21
37
  # Jump straight into device attach instead of init:
22
38
  .\install.ps1 -Device
39
+
40
+ .EXAMPLE
41
+ # Bare-metal one-shot staging install (CLI >= 1.0.10):
42
+ $env:BEEOS_API_URL = "https://public-api-staging.beeos.ai"
43
+ $env:BEEOS_AGENT_GATEWAY_URL = "https://agent-gw-staging.beeos.ai"
44
+ $env:BEEOS_DASHBOARD_URL = "https://beeos-staging-web.vercel.app"
45
+ $env:BEEOS_DEVICE_AGENT_VERSION = "0.4.1"
46
+ $env:BEEOS_MCP_SERVER_VERSION = "0.2.3"
47
+ irm https://beeos.ai/install.ps1 | iex
23
48
  #>
24
49
  param(
25
50
  [string]$Version = "latest",
@@ -15,6 +15,31 @@
15
15
  # upgrade / rebind / skip before re-running the bind flow.
16
16
  # 4. Dispatch into `beeos init` (default) or `beeos device attach` when
17
17
  # `--device` is passed.
18
+ #
19
+ # ── Staging / dev-loop env vars (CLI ≥ 1.0.10) ──────────────────────
20
+ # All four are inherited by the spawned `beeos init` / `beeos device
21
+ # attach` child via the normal `exec` env passthrough — there is no
22
+ # extra `export` needed. CLI ≥ 1.0.10 reads them via the `loadOrCreate
23
+ # Config` env-overrides layer; older CLIs only honor BEEOS_API_URL
24
+ # (telemetry) + BEEOS_AGENT_GATEWAY_URL (runtime).
25
+ #
26
+ # BEEOS_API_URL Public API base; both the script (telemetry)
27
+ # and the CLI runtime use this.
28
+ # BEEOS_AGENT_GATEWAY_URL Agent Gateway base (Ed25519-signed
29
+ # bootstrap requests).
30
+ # BEEOS_DASHBOARD_URL Dashboard base (OAuth + bind redirect).
31
+ # BEEOS_DEVICE_AGENT_VERSION Pin @beeos-ai/device-agent semver.
32
+ # BEEOS_MCP_SERVER_VERSION Pin @beeos-ai/device-mcp-server semver.
33
+ #
34
+ # Example: bare-metal one-shot staging install, including device-agent
35
+ # version pin and OAuth landing on the staging dashboard:
36
+ #
37
+ # BEEOS_API_URL=https://public-api-staging.beeos.ai \
38
+ # BEEOS_AGENT_GATEWAY_URL=https://agent-gw-staging.beeos.ai \
39
+ # BEEOS_DASHBOARD_URL=https://beeos-staging-web.vercel.app \
40
+ # BEEOS_DEVICE_AGENT_VERSION=0.4.1 \
41
+ # BEEOS_MCP_SERVER_VERSION=0.2.3 \
42
+ # curl -fsSL https://beeos.ai/install | bash -s -- --version 1.0.10
18
43
 
19
44
  set -euo pipefail
20
45