kylon-cli 0.2.0-next.154 → 0.2.0-next.155
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 +74 -21
- package/dist/kylon-bundle.mjs +1 -1
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -65,17 +65,60 @@ for the debugger-friendly tsx-based dev loop.
|
|
|
65
65
|
|
|
66
66
|
npm dist-tags are the version pointer — there is no server-side version
|
|
67
67
|
policy. Every merge to `develop` publishes a prerelease to the `next` tag
|
|
68
|
-
(`.github/workflows/cli-publish.yml`)
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
68
|
+
(`.github/workflows/cli-publish.yml`). A production deployment dispatched from
|
|
69
|
+
`main` automatically invokes the same workflow in stable mode and publishes the
|
|
70
|
+
exact `packages/cli/package.json` version to `latest`; it is idempotent when that
|
|
71
|
+
version already exists. A CLI change intended for production must therefore bump
|
|
72
|
+
the package version before the production deploy, or the stable publish will
|
|
73
|
+
correctly no-op and `latest` will remain on the existing build.
|
|
74
|
+
|
|
75
|
+
A matching `kylon-cli-vX.Y.Z` tag is an alternative supported stable-release
|
|
76
|
+
trigger, not a required extra step after a production deploy. Do not run
|
|
77
|
+
`npm publish` ad hoc: both paths use the CI workflow and its OIDC publisher.
|
|
78
|
+
Development installs `@next` and production installs `@latest`, so each
|
|
79
|
+
environment tracks its own release train.
|
|
76
80
|
|
|
77
81
|
## Usage
|
|
78
82
|
|
|
83
|
+
### Sign in for workspace commands
|
|
84
|
+
|
|
85
|
+
For a person using `kylon workspace ...` from their own terminal, open the
|
|
86
|
+
workspace's **Settings → Kylon CLI** section, expand it, and copy its setup
|
|
87
|
+
command, or run:
|
|
88
|
+
|
|
89
|
+
```bash
|
|
90
|
+
npm install -g kylon-cli@latest && kylon auth login --workspace <WORKSPACE_ID>
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
The CLI opens Kylon in your browser. After you sign in, confirm the installation
|
|
94
|
+
and workspace shown on the authorization page. Kylon then creates one credential
|
|
95
|
+
for that CLI installation and workspace. The secret is delivered directly to the
|
|
96
|
+
local CLI callback and saved in the versioned credential collection at
|
|
97
|
+
`~/.kylon/workspace-auth.json` with mode `0600`; it is not displayed in Settings.
|
|
98
|
+
The collection keeps credentials separately by server and workspace, and
|
|
99
|
+
`--scope-workspace` selects the matching entry.
|
|
100
|
+
|
|
101
|
+
Each installation credential expires after 90 days. Re-running `kylon auth
|
|
102
|
+
login` for the same installation and workspace rotates that credential, making
|
|
103
|
+
the previous value invalid. Use `kylon auth status` to inspect the bound
|
|
104
|
+
workspace and expiration time.
|
|
105
|
+
|
|
106
|
+
```bash
|
|
107
|
+
kylon auth logout --workspace <WORKSPACE_ID>
|
|
108
|
+
```
|
|
109
|
+
|
|
110
|
+
Logout revokes the selected installation credential remotely before removing
|
|
111
|
+
that entry from the local collection. With no `--workspace`, it selects the most
|
|
112
|
+
recently authorized entry. If Kylon cannot confirm revocation, it keeps the local
|
|
113
|
+
credential so you can retry. `kylon auth logout --local-only` deliberately skips
|
|
114
|
+
the remote revocation. You can also revoke any installation independently from
|
|
115
|
+
**Settings → Kylon CLI**. Other installations, browser sessions, external-agent
|
|
116
|
+
keys, and workspace service keys are unaffected.
|
|
117
|
+
|
|
118
|
+
Credentials created by the earlier browser flow appear as **Legacy user API
|
|
119
|
+
key** in Settings. They can be revoked there, but they are not bound to a single
|
|
120
|
+
workspace; sign in again to replace one with the per-installation flow.
|
|
121
|
+
|
|
79
122
|
### Onboard an invited external agent
|
|
80
123
|
|
|
81
124
|
The Web UI provides one operator-run command after an external agent is
|
|
@@ -95,6 +138,10 @@ by the displaced connection, and replaces the foreground daemon. If Codex or
|
|
|
95
138
|
Claude Code is logged out, an interactive terminal launches the provider's own
|
|
96
139
|
login flow and verifies authentication again before connecting.
|
|
97
140
|
|
|
141
|
+
External-agent onboarding is intentionally separate from human `kylon auth
|
|
142
|
+
login`: it continues to use the agent principal's API key and gateway session.
|
|
143
|
+
It does not create a human CLI installation credential.
|
|
144
|
+
|
|
98
145
|
Each invited agent is installed below `~/.kylon/agents/<agent-id>/`, so several
|
|
99
146
|
Claude Code, Codex, or mixed-provider agents can run on the same host without
|
|
100
147
|
sharing credentials or provider resume state. Different agents cannot use the
|
|
@@ -470,9 +517,10 @@ API server is the security boundary.
|
|
|
470
517
|
|
|
471
518
|
The CLI ships via **npm dist-tags** — there is no server-side version policy.
|
|
472
519
|
`cli-verify.yml` validates on PRs and pushes; `cli-publish.yml` publishes via
|
|
473
|
-
OIDC (no token): a prerelease to the `next` tag on every merge to
|
|
474
|
-
|
|
475
|
-
|
|
520
|
+
OIDC (no token): a prerelease to the `next` tag on every qualifying merge to
|
|
521
|
+
`develop`, and the package version to `latest` when the production deploy runs
|
|
522
|
+
from `main`. A matching `kylon-cli-vX.Y.Z` tag can also publish that stable
|
|
523
|
+
version. Development installs `@next`; production installs `@latest`.
|
|
476
524
|
|
|
477
525
|
### Versioning
|
|
478
526
|
|
|
@@ -484,18 +532,23 @@ Use explicit semver in `packages/cli/package.json`:
|
|
|
484
532
|
| minor (`0.1.x → 0.2.0`) | backward-compatible capability (new command, new flag) |
|
|
485
533
|
| major (`0.x.x → 1.0.0`) | breaking change to CLI contract or runtime behavior |
|
|
486
534
|
|
|
487
|
-
Prerelease builds are versioned
|
|
488
|
-
`cli-publish.yml
|
|
489
|
-
`packages/cli/package.json`
|
|
490
|
-
|
|
535
|
+
Prerelease builds are versioned `<package-version>-next.<run>` automatically by
|
|
536
|
+
`cli-publish.yml`. Stable mode publishes the exact package version and skips
|
|
537
|
+
idempotently if npm already has it. Bump `packages/cli/package.json` whenever a
|
|
538
|
+
new production CLI build must be published; otherwise the production deploy
|
|
539
|
+
will intentionally leave `latest` unchanged.
|
|
491
540
|
|
|
492
541
|
### Publishing
|
|
493
542
|
|
|
494
|
-
- **Prerelease (automatic):** every merge to `
|
|
495
|
-
|
|
543
|
+
- **Prerelease (automatic):** every merge to `develop` touching the CLI publishes
|
|
544
|
+
`<package-version>-next.<run>` to the `next` tag via `cli-publish.yml` (OIDC, no
|
|
496
545
|
`NPM_TOKEN`). dev tracks this tag, so dev always dogfoods the newest build.
|
|
497
|
-
- **Stable (
|
|
498
|
-
|
|
546
|
+
- **Stable (automatic with a production deploy):** a production deployment
|
|
547
|
+
dispatched from `main` calls `cli-publish.yml` in stable mode. It publishes
|
|
548
|
+
the package version only when that exact version is absent from npm. CLI
|
|
549
|
+
changes therefore need a package-version bump before the production deploy.
|
|
550
|
+
- **Stable tag (alternative):** after bumping the package version, a matching
|
|
551
|
+
tag on `main` invokes the same stable workflow directly:
|
|
499
552
|
|
|
500
553
|
```bash
|
|
501
554
|
git pull
|
|
@@ -504,8 +557,8 @@ Prerelease builds are versioned `0.1.0-next.<run>` automatically by
|
|
|
504
557
|
npm view kylon-cli dist-tags # verify
|
|
505
558
|
```
|
|
506
559
|
|
|
507
|
-
|
|
508
|
-
|
|
560
|
+
Do not `npm publish` ad hoc: production deploys and release tags both go through
|
|
561
|
+
the workflow so the OIDC provenance path is exercised end to end.
|
|
509
562
|
|
|
510
563
|
### Rollback
|
|
511
564
|
|