@synopackageland/cli 0.48.5 → 0.48.6
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 -7
- package/package.json +2 -1
- package/skills/SKILL.md +5 -2
- package/skills/reference/compose.md +4 -2
- package/skills/reference/create.md +2 -0
- package/skills/reference/ctl.md +1 -1
- package/skills/reference/identity-gateway.md +4 -2
- package/skills/reference/install.md +3 -1
- package/skills/reference/lifecycle.md +3 -3
package/README.md
CHANGED
|
@@ -89,9 +89,9 @@ alongside npm lockfiles. Do not disable checksum verification for public SDK
|
|
|
89
89
|
packages. Private mirrors can use explicitly configured Go authentication and
|
|
90
90
|
checksum settings; a failed fetch reports `SDK_DOWNLOAD_FAILED`.
|
|
91
91
|
|
|
92
|
-
The CLI pins
|
|
93
|
-
context. Explicit App SDK declarations take precedence.
|
|
94
|
-
|
|
92
|
+
The CLI pins an SDK release for its daemon controllers, Compose planning and installer
|
|
93
|
+
context. Explicit App SDK declarations take precedence. Locally installed templates
|
|
94
|
+
retain their own scaffold SDK pins; none declare daemon ingress.
|
|
95
95
|
Every App method is declared once in operations.json; ctl generate writes the
|
|
96
96
|
permissions table and runtime bindings. Dynamic names and custom HTTP dispatchers
|
|
97
97
|
are rejected. Use fixed
|
|
@@ -102,8 +102,8 @@ unimported development commands are excluded. Use
|
|
|
102
102
|
authentication. See [App entry and registration](docs/app-entry.md).
|
|
103
103
|
|
|
104
104
|
`init` and `add` read their templates from the locally installed
|
|
105
|
-
`@synopackageland/templates`. The CLI
|
|
106
|
-
|
|
105
|
+
`@synopackageland/templates`. The CLI's npm dependency range selects compatible
|
|
106
|
+
templates patches during installation or update. Templates
|
|
107
107
|
patches need only a templates release; update the npm installation to receive them.
|
|
108
108
|
The CLI never fetches templates at runtime, so offline use works after installation;
|
|
109
109
|
commit a lockfile and use `npm ci` to reproduce a chosen dependency tree.
|
|
@@ -364,7 +364,7 @@ contract for the complete transport and CGI validation rules.
|
|
|
364
364
|
|
|
365
365
|
`webapi.call` request parameters are JSON-only; it has no request upload field.
|
|
366
366
|
Use streaming `files.write` for uploads, up to 100 MiB per file. Reads and URL
|
|
367
|
-
downloads retain their separate 64 MiB limit. Rebuild with SDK
|
|
367
|
+
downloads retain their separate 64 MiB limit. Rebuild with an SDK that supports the requested file descriptor budget and approve
|
|
368
368
|
the refreshed executor payload.
|
|
369
369
|
|
|
370
370
|
## App launch mode
|
|
@@ -629,7 +629,7 @@ package start activates nginx.
|
|
|
629
629
|
|
|
630
630
|
Older SDK/DSM targets retain the direct listener and explain its certificate or
|
|
631
631
|
unencrypted-HTTP limitations before opening it. Native resource/startup failures
|
|
632
|
-
fail closed; they do not silently expose a direct listener. The native runtime uses the resolved SDK release; new scaffolds pin the SDK
|
|
632
|
+
fail closed; they do not silently expose a direct listener. The native runtime uses the resolved SDK release; new scaffolds pin the SDK selected by the installed templates.
|
|
633
633
|
|
|
634
634
|
Compose Apps may opt in to Intel render devices with
|
|
635
635
|
`compose.devices.gpu.services: [media]`. The matching SDK discovers exact devices
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@synopackageland/cli",
|
|
3
|
-
"version": "0.48.
|
|
3
|
+
"version": "0.48.6",
|
|
4
4
|
"description": "Syno Package Land Developer Kit CLI",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -19,6 +19,7 @@
|
|
|
19
19
|
"docs/shared-folders.md"
|
|
20
20
|
],
|
|
21
21
|
"scripts": {
|
|
22
|
+
"check:docs": "node --test scripts/check-doc-versions.test.mjs && node scripts/check-doc-versions.mjs",
|
|
22
23
|
"build": "rm -rf dist && tsc",
|
|
23
24
|
"test": "npm run build && node --import tsx --test --test-concurrency=${SYNOPKGLAND_GATE_JOBS:-3} test/*.test.ts test/ctl/*.test.ts",
|
|
24
25
|
"test:glossary": "node --test scripts/test/glossary-drift.test.mjs",
|
package/skills/SKILL.md
CHANGED
|
@@ -5,7 +5,7 @@ description: Initialize, extend, check, build, inspect, and deploy Synology appl
|
|
|
5
5
|
|
|
6
6
|
# Independent Synology SPKs
|
|
7
7
|
|
|
8
|
-
The CLI installs templates through
|
|
8
|
+
The CLI installs templates through its declared npm dependency range. A templates patch needs only a
|
|
9
9
|
templates release; npm install/update selects a patch in that minor line. The CLI
|
|
10
10
|
uses the locally installed templates and reads their SDK pin for defaults; it
|
|
11
11
|
never downloads templates at runtime. Preserve the lockfile and use `npm ci` for
|
|
@@ -14,7 +14,10 @@ the CLI: executor manifest format 1 in the resolved SDK pins the executor releas
|
|
|
14
14
|
Go toolchain and six payload digests. Preserve npm integrity and Go module sums.
|
|
15
15
|
The CLI verifies bytes before packaging and never fetches a manifest at NAS runtime.
|
|
16
16
|
Unsupported formats require a CLI update; invalid manifests fail closed.
|
|
17
|
-
|
|
17
|
+
Scaffolds pin matching SDK/App releases and declare operations in one v2 registry.
|
|
18
|
+
Query published releases with `npm view @synopackageland/cli version`,
|
|
19
|
+
`npm view @synopackageland/templates version` and `npm view @synopackageland/sdk version`;
|
|
20
|
+
keep the installed dependency tree and generated pins consistent.
|
|
18
21
|
|
|
19
22
|
For Apps with data folders or gateway listeners, read [reference/install.md](reference/install.md). Default to an App-named dedicated DSM data share and installer-selected ports. Existing-folder access, port number format/range and required HTTPS origins use localized wizard validation before Next; detected port conflicts are nonblocking inline warnings, and an unavailable DSM port inventory does not block installation; upgrades retain port selections.
|
|
20
23
|
|
|
@@ -4,6 +4,8 @@ The CLI converts schema-2 declarations to an SPK. The SDK owns Compose planning,
|
|
|
4
4
|
identity gateway and lifecycle control. There is no separate wrapper container
|
|
5
5
|
or SSO Server. Upstream files stay byte-for-byte unchanged, including comments.
|
|
6
6
|
|
|
7
|
+
`<sdk-version>` is a placeholder, not manifest syntax. `synopkgland init` copies compatible SDK pins from the locally installed templates. For a manual configuration, query `npm view @synopackageland/sdk version`, replace the placeholder with that exact release, and keep all App SDK declarations (including Go, Rust and frontend dependencies) aligned. Run `synopkgland check` with an up-to-date CLI before building.
|
|
8
|
+
|
|
7
9
|
```yaml
|
|
8
10
|
schema: 2
|
|
9
11
|
package: MediaApp
|
|
@@ -39,7 +41,7 @@ architecture-specific native payloads for token/account adapters. All lifecycle
|
|
|
39
41
|
scripts run as the package account; containers are managed by Container Manager.
|
|
40
42
|
|
|
41
43
|
For external access, pin both `compose.sdk` and `identity_gateway.sdk` to
|
|
42
|
-
the
|
|
44
|
+
the same release with external access support and use the gateway's
|
|
43
45
|
[`external_access` policy and DSM settings entry](identity-gateway.md#external-access).
|
|
44
46
|
Declare required HTTPS origins through `install.settings`; wizard validation checks the selected HTTPS port before Next. See [install.md](install.md).
|
|
45
47
|
Manual URL configuration does not require Connect. The SDK resolves the public
|
|
@@ -260,7 +262,7 @@ declared availability readiness, LAN isolation/egress, protected grant lifecycle
|
|
|
260
262
|
ACLs, two-user visibility and clean install/upgrade/reboot/stop/uninstall before
|
|
261
263
|
calling the package supported on a NAS. No NAS is accessed by the build gate.
|
|
262
264
|
|
|
263
|
-
The unified Compose contract uses SDK defaults from
|
|
265
|
+
The unified Compose contract uses SDK defaults from locally installed templates and a matching CLI. Templates patches can ship independently; npm install/update resolves them, and SDK defaults come from the installed templates. SDK minor upgrades do not require a CLI release when they declare supported executor manifest format 1; the resolved SDK owns the release mapping and verified payload digests. The CLI does not fetch templates at runtime. The legacy packaging route and bridge publish mode are removed.
|
|
264
266
|
|
|
265
267
|
Primary override files, and each included override set, must share a directory. Cross-directory override bases are rejected before loader I/O. Included implicit .env files are confined, inventoried and preserved; symlinks are rejected.
|
|
266
268
|
|
|
@@ -45,6 +45,8 @@ rootOps 與 delegate 已共用管理員 PasswordConfirm 核准的 protected exec
|
|
|
45
45
|
|
|
46
46
|
backend 寫 `runtime: python|node|rust`(`runtime: go` 等同 `kind: go`)。CGI 是 SDK 的 Go runtime(`bridge/cmd/runtime`),它驗證 DSM session、entry 與 `permissions.json` 後,以套件帳號(不是 root)每個請求啟動一次 App。App 放在 ui 以外的目錄,打包成 `target/app/`,build 寫入 `bridge.json`(spec/bridge/v1)並把它與 `permissions.json` 的 sha256 編進 runtime。
|
|
47
47
|
|
|
48
|
+
`<sdk-version>` is a placeholder, not manifest syntax. `synopkgland init` copies compatible SDK pins from the locally installed templates. For a manual configuration, query `npm view @synopackageland/sdk version`, replace the placeholder with that exact release, and keep all App SDK declarations (including Go, Rust and frontend dependencies) aligned. Run `synopkgland check` with an up-to-date CLI before building.
|
|
49
|
+
|
|
48
50
|
```yaml
|
|
49
51
|
backend: {runtime: python, dir: app, entry: main.py, sdk: <sdk-version>}
|
|
50
52
|
backend: {runtime: node, dir: app, entry: main.mjs, sdk: <sdk-version>, node: {package: Node.js_v22}}
|
package/skills/reference/ctl.md
CHANGED
|
@@ -157,7 +157,7 @@ direction, including hidden routes. The only infrastructure exceptions are the
|
|
|
157
157
|
fixed describe and identity ceremony methods. SDK capability metadata comes from
|
|
158
158
|
the SDK's own hidden catalog and can be explicitly overridden in the App spec.
|
|
159
159
|
Never hand-edit generated operation descriptions or add them to a skill manually.
|
|
160
|
-
|
|
160
|
+
Use the SDK pins in the project generated by `synopkgland init`; query published releases with `npm view @synopackageland/sdk version`, `npm view @synopackageland/templates version` and `npm view @synopackageland/cli version`.
|
|
161
161
|
|
|
162
162
|
For installed Apps, use `ctl tools <app> --host <profile>` and
|
|
163
163
|
`ctl tool <app> <method> --input <file|-> --host <profile>`. These require the
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
## Upstream-authenticated paths
|
|
4
4
|
|
|
5
|
-
Build with
|
|
5
|
+
Build with matching SDK and CLI releases. Use `upstream_auth_paths` for client API
|
|
6
6
|
paths that use upstream authentication.
|
|
7
7
|
|
|
8
8
|
Keep browser routes behind `entry: admin-only` or `entry: app-privilege`; list
|
|
@@ -22,9 +22,11 @@ See `docs/app-entry.md` for the complete contract.
|
|
|
22
22
|
|
|
23
23
|
## External access
|
|
24
24
|
|
|
25
|
-
Use
|
|
25
|
+
Use an SDK with matching gateway sources. Add this to the existing
|
|
26
26
|
complete gateway declaration; keep the App's upstream, listener and auth policy:
|
|
27
27
|
|
|
28
|
+
`<sdk-version>` is a placeholder, not manifest syntax. `synopkgland init` copies compatible SDK pins from the locally installed templates. For a manual configuration, query `npm view @synopackageland/sdk version`, replace the placeholder with that exact release, and keep all App SDK declarations (including Go, Rust and frontend dependencies) aligned. Run `synopkgland check` with an up-to-date CLI before building.
|
|
29
|
+
|
|
28
30
|
```yaml
|
|
29
31
|
identity_gateway:
|
|
30
32
|
sdk: <sdk-version>
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
# Native installation settings
|
|
2
2
|
|
|
3
|
-
Use
|
|
3
|
+
Use matching CLI, SDK/App and templates releases, preserving the pins generated by `synopkgland init`. Configure installation through the manifest and generated wizard; do not add App ACL writers, root hooks or independent port state.
|
|
4
|
+
|
|
5
|
+
`<sdk-version>` is a placeholder, not manifest syntax. `synopkgland init` copies compatible SDK pins from the locally installed templates. For a manual configuration, query `npm view @synopackageland/sdk version`, replace the placeholder with that exact release, and keep all App SDK declarations (including Go, Rust and frontend dependencies) aligned. Run `synopkgland check` with an up-to-date CLI before building.
|
|
4
6
|
|
|
5
7
|
```yaml
|
|
6
8
|
install:
|
|
@@ -139,9 +139,9 @@ by these settings.
|
|
|
139
139
|
|
|
140
140
|
Native daemon Apps may opt in with `daemon.nofile: 32768`. The value must be an
|
|
141
141
|
integer from 1024 to 1048576; omission keeps the legacy controller path. This
|
|
142
|
-
requires DSM 7.0-40761 or later and
|
|
143
|
-
|
|
144
|
-
|
|
142
|
+
requires DSM 7.0-40761 or later and an SDK with file descriptor budget support,
|
|
143
|
+
including any explicit Go App or gateway SDK pin. Check and build reject
|
|
144
|
+
unsupported pins; build also verifies matching controller sources.
|
|
145
145
|
|
|
146
146
|
The CLI generates only `conf/systemd/pkg-<package>-daemon.service`. DSM acquires
|
|
147
147
|
this fixed system unit directly; it needs no `systemd-user-unit` resource
|