vana-cli 0.26.0 → 0.28.0
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/README.md +7 -0
- package/dist/cli/index.d.ts.map +1 -1
- package/dist/cli/index.js +28 -0
- package/dist/cli/index.js.map +1 -1
- package/dist/cli/server-start.d.ts +14 -1
- package/dist/cli/server-start.d.ts.map +1 -1
- package/dist/cli/server-start.js +207 -5
- package/dist/cli/server-start.js.map +1 -1
- package/dist/personal-server/local/config.d.ts +5 -0
- package/dist/personal-server/local/config.d.ts.map +1 -1
- package/dist/personal-server/local/config.js +4 -2
- package/dist/personal-server/local/config.js.map +1 -1
- package/dist/personal-server/local/detach.d.ts +29 -0
- package/dist/personal-server/local/detach.d.ts.map +1 -0
- package/dist/personal-server/local/detach.js +134 -0
- package/dist/personal-server/local/detach.js.map +1 -0
- package/dist/personal-server/local/frpc.d.ts +59 -0
- package/dist/personal-server/local/frpc.d.ts.map +1 -0
- package/dist/personal-server/local/frpc.js +191 -0
- package/dist/personal-server/local/frpc.js.map +1 -0
- package/dist/personal-server/local/owner-binding.d.ts +22 -2
- package/dist/personal-server/local/owner-binding.d.ts.map +1 -1
- package/dist/personal-server/local/owner-binding.js +23 -14
- package/dist/personal-server/local/owner-binding.js.map +1 -1
- package/dist/personal-server/local/registration.d.ts +42 -0
- package/dist/personal-server/local/registration.d.ts.map +1 -0
- package/dist/personal-server/local/registration.js +81 -0
- package/dist/personal-server/local/registration.js.map +1 -0
- package/dist/personal-server/local/runtime-pkg/entry.mjs +138 -20
- package/dist/personal-server/local/server.d.ts +25 -0
- package/dist/personal-server/local/server.d.ts.map +1 -1
- package/dist/personal-server/local/server.js +80 -4
- package/dist/personal-server/local/server.js.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -43,6 +43,13 @@ vana server status # your server, local and registered URLs
|
|
|
43
43
|
vana server start # run your own server here when Vana Desktop is not
|
|
44
44
|
```
|
|
45
45
|
|
|
46
|
+
`vana server start` is local only: `vana connect` writes to it, apps cannot
|
|
47
|
+
reach it. `vana server start --public` registers it on-chain for your
|
|
48
|
+
account, opens a public URL through Vana's relay, syncs to Vana storage, and
|
|
49
|
+
stays public on every later start. A registration cannot be removed, so this
|
|
50
|
+
is a step you take on purpose. On a Mac the tunnel client is a build of frpc
|
|
51
|
+
signed and notarized by Vana (or Vana Desktop's copy, when installed).
|
|
52
|
+
|
|
46
53
|
**Builder side** is what an app or an agent uses to work with someone
|
|
47
54
|
else's data, with their consent:
|
|
48
55
|
|
package/dist/cli/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/cli/index.ts"],"names":[],"mappings":"AAwCA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,8BAA8B,CAAC;AACpE,OAAO,EAQL,YAAY,EAIb,MAAM,kBAAkB,CAAC;AAY1B,OAAO,KAAK,EACV,UAAU,EAEV,gBAAgB,EAEhB,SAAS,EACT,YAAY,EACb,MAAM,sBAAsB,CAAC;AAC9B,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,2BAA2B,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/cli/index.ts"],"names":[],"mappings":"AAwCA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,8BAA8B,CAAC;AACpE,OAAO,EAQL,YAAY,EAIb,MAAM,kBAAkB,CAAC;AAY1B,OAAO,KAAK,EACV,UAAU,EAEV,gBAAgB,EAEhB,SAAS,EACT,YAAY,EACb,MAAM,sBAAsB,CAAC;AAC9B,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,2BAA2B,CAAC;AAkKjE,UAAU,cAAc;IACtB,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAAC;CAC1B;AAED,UAAU,iBAAiB;IACzB,CAAC,MAAM,EAAE,MAAM,GAAG;QAChB,IAAI,EAAE,MAAM,CAAC;QACb,OAA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AsB,iBAAiB,CACrC,UAAU,EAAE,MAAM,GACjB,OAAO,CAAC;IAAE,KAAK,EAAE,MAAM,EAAE,CAAA;CAAE,GAAG,IAAI,CAAC,CAOrC;AAED,wBAAgB,mBAAmB,CACjC,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAC5B;IAAE,KAAK,EAAE,MAAM,EAAE,CAAA;CAAE,GAAG,IAAI,CAoD5B;AA6BD,wBAAgB,eAAe,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,CAUrD;AAED,wBAAgB,mBAAmB,CACjC,IAAI,EAAE;IACJ,SAAS,EAAE,MAAM,GAAG,IAAI,CAAC;IACzB,IAAI,EAAE,MAAM,GAAG,SAAS,CAAC;IACzB,MAAM,EAAE,MAAM,CAAC;CAChB,EACD,KAAK,EAAE;IACL,SAAS,EAAE,MAAM,GAAG,IAAI,CAAC;IACzB,IAAI,EAAE,MAAM,GAAG,SAAS,CAAC;IACzB,MAAM,EAAE,MAAM,CAAC;CAChB,GACA,MAAM,CAaR;AAsBD,wBAAgB,gBAAgB,CAC9B,SAAS,EAAE,YAAY,CAAC,WAAW,CAAC,GAAG,IAAI,GAAG,SAAS,GACtD,OAAO,CAOT;AAqMD,qBAAa,2BAA4B,SAAQ,KAAK;CAAG;AAEzD;;;;;;;;;GASG;AACH,wBAAgB,uBAAuB,CACrC,aAAa,GAAE,gBAAwC,EACvD,QAAQ,SAAmB,EAC3B,WAAW,SAAkB,GAC5B,MAAM,EAAE,CAkBV;AAgDD,wBAAgB,oBAAoB,CAClC,WAAW,EAAE,MAAM,EAAE,EACrB,eAAe,EAAE,MAAM,GACtB,MAAM,CA+BR"}
|
package/dist/cli/index.js
CHANGED
|
@@ -38,6 +38,7 @@ import { detectPersonalServerTarget, ingestResult, personalServerOwnerMismatch,
|
|
|
38
38
|
import { findDataConnectorsDir, ManagedPlaywrightRuntime, } from "../runtime/index.js";
|
|
39
39
|
import { getPdppProfileRoot } from "../pdpp/host.js";
|
|
40
40
|
import { runServerStart } from "./server-start.js";
|
|
41
|
+
import { stopLocalServer } from "../personal-server/local/detach.js";
|
|
41
42
|
import { isPdppSource, PdppRuntime } from "../pdpp/runtime.js";
|
|
42
43
|
import { listAvailableSkills, installSkill, readInstalledSkills, } from "../skills/index.js";
|
|
43
44
|
import { queryStatus, querySources, queryDataList, queryDataShow, queryDoctor, } from "./queries.js";
|
|
@@ -411,6 +412,8 @@ Examples:
|
|
|
411
412
|
Examples:
|
|
412
413
|
vana server
|
|
413
414
|
vana server start
|
|
415
|
+
vana server start --detach
|
|
416
|
+
vana server stop
|
|
414
417
|
vana server set-url http://localhost:8080
|
|
415
418
|
vana server set-url https://ps-abc123.server.vana.org
|
|
416
419
|
vana server clear-url
|
|
@@ -443,6 +446,8 @@ Examples:
|
|
|
443
446
|
.command("start")
|
|
444
447
|
.description("Run your own Personal Server here, in the foreground, when Vana Desktop is not running one")
|
|
445
448
|
.option("--port <port>", "Port to listen on (its neighbour hosts the approval page)")
|
|
449
|
+
.option("--local", "Stay local only: no public URL, no on-chain registration, apps cannot reach it")
|
|
450
|
+
.option("--detach", "Run in the background; stop with `vana server stop`")
|
|
446
451
|
.option("--json", "Output machine-readable JSON")
|
|
447
452
|
.action(async (startOptions) => {
|
|
448
453
|
process.exitCode = await runCommandWithTelemetry({ ...telemetryBaseContext, command: "server", subcommand: "start" }, async () => {
|
|
@@ -459,6 +464,8 @@ Examples:
|
|
|
459
464
|
port,
|
|
460
465
|
noInput: parsedOptions.noInput,
|
|
461
466
|
yes: parsedOptions.yes,
|
|
467
|
+
local: startOptions.local,
|
|
468
|
+
detach: parsedOptions.detach,
|
|
462
469
|
}, {
|
|
463
470
|
say: (line) => {
|
|
464
471
|
if (!parsedOptions.json)
|
|
@@ -472,6 +479,27 @@ Examples:
|
|
|
472
479
|
});
|
|
473
480
|
});
|
|
474
481
|
});
|
|
482
|
+
server
|
|
483
|
+
.command("stop")
|
|
484
|
+
.description("Stop the Personal Server `vana server start` runs here")
|
|
485
|
+
.option("--json", "Output machine-readable JSON")
|
|
486
|
+
.action(async () => {
|
|
487
|
+
process.exitCode = await runCommandWithTelemetry({ ...telemetryBaseContext, command: "server", subcommand: "stop" }, async () => {
|
|
488
|
+
const network = resolveNetwork(parsedOptions.network).name;
|
|
489
|
+
const result = await stopLocalServer(network);
|
|
490
|
+
if (parsedOptions.json) {
|
|
491
|
+
process.stdout.write(`${JSON.stringify({ type: "server-stop", result, network })}\n`);
|
|
492
|
+
}
|
|
493
|
+
else {
|
|
494
|
+
process.stderr.write(`${result === "stopped"
|
|
495
|
+
? "Stopped."
|
|
496
|
+
: result === "not-running"
|
|
497
|
+
? `No Personal Server started by vana is running (${network}).`
|
|
498
|
+
: "The server did not stop in time."}\n`);
|
|
499
|
+
}
|
|
500
|
+
return result === "timeout" ? CliExitCode.FAILURE : CliExitCode.OK;
|
|
501
|
+
});
|
|
502
|
+
});
|
|
475
503
|
server
|
|
476
504
|
.command("sync")
|
|
477
505
|
.description("Sync all local-only datasets to your Personal Server")
|