@lenso/cli 0.2.17 → 0.3.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 CHANGED
@@ -10,22 +10,42 @@ npm install -g @lenso/cli
10
10
  cargo install lenso-cli
11
11
  ```
12
12
 
13
- ## Scaffold a host application
13
+ ## Application lifecycle
14
14
 
15
15
  ```sh
16
- lenso host init my-app
17
- cd my-app
18
- cp .env.example .env
19
- lenso serve
16
+ lenso app compose ./support-desk \
17
+ --blueprint support-desk \
18
+ --implementation support-api=linked \
19
+ --apply
20
+ cd support-desk
21
+ lenso system dev
20
22
  ```
21
23
 
22
- The package name defaults to the target directory name and can be overridden with
23
- `--name`. Pass `--force` to scaffold into a non-empty directory.
24
+ `lenso app compose` writes the exact `lenso.app.json` App Composition and lock.
25
+ Its `--apply` flag atomically materializes that composition in the same command;
26
+ it is not a separate lifecycle stage and does not create a plan artifact. The
27
+ public application path is Compose, Run locally, Connect, and Status. Connect
28
+ and Status happen in Lenso Console through a signed enrollment exchange. The
29
+ CLI does not select an environment, deploy the application, release it, or
30
+ connect it to Console.
31
+
32
+ `lenso system check` remains a contract-validation command. `lenso host init`
33
+ and `lenso serve` remain lower-level host development tools, not alternative
34
+ application lifecycle stages.
24
35
 
25
- ## Install Lenso Console
36
+ The former App Plan, Apply, Verify, Diff, Repair, Next, Upgrade, and Explain
37
+ commands and the former System Init, AddService, AddModule, Plan, Diff, Apply,
38
+ Doctor, Release, Runbook, and Graph commands are no longer public entrypoints.
39
+ `lenso app compose` also no longer accepts `--write-plan`, `--explain`, or
40
+ `--addon`. Its surviving `--apply` option is only the atomic materialization
41
+ flag described above, not an Apply stage.
42
+
43
+ ## Provision Lenso Console independently
26
44
 
27
45
  Lenso Console is installed as an independent Service, not embedded into a
28
- business Service. Obtain an official GitHub-attested Console Release Manifest,
46
+ business Service. Provisioning Console is separate from connecting an
47
+ application and does not grant Console production deployment or release
48
+ authority. Obtain an official GitHub-attested Console Release Manifest,
29
49
  review the deterministic plan, and then approve that exact plan digest:
30
50
 
31
51
  ```sh
@@ -216,8 +236,8 @@ running until Ctrl-C. New hosts run them in one local process; pass
216
236
  lenso module create billing
217
237
  ```
218
238
 
219
- Add `--with-console-ui` when the Module Release should also contain its isolated
220
- Console UI artifact:
239
+ Add `--with-console-ui` when the Module Release should also contain its verified
240
+ same-realm ESM Console UI artifact:
221
241
 
222
242
  ```sh
223
243
  lenso module create billing --with-console-ui
@@ -257,6 +277,47 @@ lenso system dev --scenario deadline-timeout --json
257
277
  lenso system dev --cleanup
258
278
  ```
259
279
 
280
+ For a new product-shaped application, materialize one exact App Composition
281
+ instead of layering generated state. The blueprint and implementation overrides
282
+ are composition inputs; `lenso.app.json` is the only application composition
283
+ and lock, with immutable Module release digests, implementation bindings,
284
+ resolved dependency selections, and an optimistic revision:
285
+
286
+ ```sh
287
+ lenso app compose ./support-desk --blueprint support-desk --apply
288
+ lenso app compose --repo-root ./support-desk \
289
+ --implementation support-api=linked \
290
+ --observed-revision 1 --apply
291
+ lenso system dev --system-file ./support-desk/lenso.app.json --dry-run --json
292
+ lenso system dev --system-file ./support-desk/lenso.app.json
293
+ ```
294
+
295
+ `lenso system dev` realizes service-backed bindings through a persistent Local
296
+ Control Adapter. The coordinator may exit after reporting workload identities;
297
+ the adapter and its explicitly started local workloads remain active. Use
298
+ `lenso system dev --system-file ./support-desk/lenso.app.json --cleanup` to
299
+ stop only the adapter-owned workloads. This path does not create a second App
300
+ lock or copy process commands into `lenso.app.json`.
301
+
302
+ The adapter state under `.lenso/local-control-adapter/<appId>/state.json`
303
+ advertises its `adapterId`, exact `adapterWorkload`, loopback `endpoint`,
304
+ `workloadControlProtocol`, `workloadControlSchemaDigest`, and exact
305
+ `capabilities`. Without a server-side
306
+ `LENSO_WORKLOAD_CONTROL_TOKEN` override, startup creates an owner-only local
307
+ credential file and records only its `credentialFile` reference; the bearer
308
+ token is never serialized into adapter state or HTTP responses.
309
+
310
+ The Local Control Adapter advertises and accepts only `suspend` and `resume`.
311
+ Each accepted mutation returns an asynchronous Operation Record identified by
312
+ `operationId`; callers poll that handle for the Adapter's final result.
313
+
314
+ Until the Workload Control contract from
315
+ [LioRael/lenso#530](https://github.com/LioRael/lenso/pull/530) is published,
316
+ the CLI keeps a private, frozen mirror of its wire DTOs and constants. The
317
+ advertised schema digest and protocol conformance tests pin that bounded mirror
318
+ to the reviewed contract without adding an unpublished dependency to the CLI
319
+ package.
320
+
260
321
  The System graph remains in `lenso.system.json`. Local-only executable details
261
322
  live beside it in `lenso.system-sandbox.json`:
262
323
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lenso/cli",
3
- "version": "0.2.17",
3
+ "version": "0.3.0",
4
4
  "description": "Lenso command-line interface for scaffolding and operating Lenso backend projects.",
5
5
  "license": "MIT",
6
6
  "homepage": "https://github.com/LioRael/lenso-cli",
Binary file
Binary file
Binary file
Binary file