@kitsy/cnos-docs 1.8.3 → 1.9.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/docs/cli/build.mdx +16 -0
- package/docs/cli/define.mdx +21 -0
- package/docs/cli/diff.mdx +2 -2
- package/docs/cli/help-ai.mdx +21 -0
- package/docs/cli/help.mdx +22 -0
- package/docs/cli/index.mdx +4 -3
- package/docs/cli/list.mdx +23 -0
- package/docs/cli/profile.mdx +23 -0
- package/docs/cli/run.mdx +4 -0
- package/docs/cli/ui.mdx +42 -0
- package/docs/cli/use.mdx +22 -0
- package/docs/cli/vault.mdx +3 -1
- package/docs/cli/version.mdx +21 -0
- package/docs/guides/profiles.mdx +1 -1
- package/docs/reference/namespaces.mdx +1 -1
- package/docs/reference/security.mdx +2 -1
- package/manifest.yml +17 -1
- package/package.json +1 -1
package/docs/cli/build.mdx
CHANGED
|
@@ -12,6 +12,7 @@ cnos build server --to .cnos-server.json
|
|
|
12
12
|
cnos build browser --to .cnos-browser.json
|
|
13
13
|
cnos build env --profile local --to .env.local
|
|
14
14
|
cnos build env --profile stage --to .env.stage
|
|
15
|
+
cnos build env --profile prod --reveal --to .env.production.local
|
|
15
16
|
cnos build public --framework vite --to .env.production
|
|
16
17
|
cnos build env --profile local-domain --format docker-env --to .env.local-domain
|
|
17
18
|
```
|
|
@@ -24,3 +25,18 @@ Targets:
|
|
|
24
25
|
- `build public` writes promoted public env with optional framework prefixes like Vite and Next
|
|
25
26
|
|
|
26
27
|
All build artifacts are derived output. `.cnos` remains the source of truth.
|
|
28
|
+
|
|
29
|
+
## Writing secrets into env artifacts
|
|
30
|
+
|
|
31
|
+
By default, `build env` masks secret env mappings as `****`.
|
|
32
|
+
|
|
33
|
+
Use `--reveal` only when you intentionally want concrete secret values in the generated artifact:
|
|
34
|
+
|
|
35
|
+
```bash
|
|
36
|
+
cnos build env --profile prod --reveal --to .env.production.local
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
CNOS protects this path in two ways:
|
|
40
|
+
|
|
41
|
+
- it verifies that the target file is gitignored before writing secrets
|
|
42
|
+
- in interactive terminals it prints a warning prompt before continuing
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: cnos define
|
|
3
|
+
description: Write a value or secret through CNOS write policy.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# cnos define
|
|
7
|
+
|
|
8
|
+
Use `cnos define` when you want CNOS to choose the correct target file for a `value.*` or `secret.*` write.
|
|
9
|
+
|
|
10
|
+
## Usage
|
|
11
|
+
|
|
12
|
+
```bash
|
|
13
|
+
cnos define <value|secret> <path> <rawValue> [--target <local|global>] [--workspace <id>] [--profile <name>]
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
## Examples
|
|
17
|
+
|
|
18
|
+
```bash
|
|
19
|
+
cnos define value server.port 3000 --workspace api
|
|
20
|
+
cnos define secret app.token super-secret --workspace api
|
|
21
|
+
```
|
package/docs/cli/diff.mdx
CHANGED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: cnos help-ai
|
|
3
|
+
description: Show machine-readable CLI help for agents and automation.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# cnos help-ai
|
|
7
|
+
|
|
8
|
+
`cnos help-ai` is the canonical machine-readable CLI surface. JSON is the default output format.
|
|
9
|
+
|
|
10
|
+
## Usage
|
|
11
|
+
|
|
12
|
+
```bash
|
|
13
|
+
cnos help-ai [command] [--format <json|text>]
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
## Examples
|
|
17
|
+
|
|
18
|
+
```bash
|
|
19
|
+
cnos help-ai --format json
|
|
20
|
+
cnos help-ai export env --format json
|
|
21
|
+
```
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: cnos help
|
|
3
|
+
description: Show human-readable CLI help for the root command set or one topic.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# cnos help
|
|
7
|
+
|
|
8
|
+
Use `cnos help` when you want the checked-in command list and detailed usage for a topic.
|
|
9
|
+
|
|
10
|
+
## Usage
|
|
11
|
+
|
|
12
|
+
```bash
|
|
13
|
+
cnos help [command]
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
## Examples
|
|
17
|
+
|
|
18
|
+
```bash
|
|
19
|
+
cnos help
|
|
20
|
+
cnos help define
|
|
21
|
+
cnos help export env
|
|
22
|
+
```
|
package/docs/cli/index.mdx
CHANGED
|
@@ -8,8 +8,9 @@ description: Overview of the CNOS CLI surface and command groups.
|
|
|
8
8
|
The CLI is organized around:
|
|
9
9
|
|
|
10
10
|
- setup: `init`, `onboard`, `use`, `profile`
|
|
11
|
-
- data operations: `read`, `value`, `secret`, `promote`
|
|
12
|
-
- workflows: `build env`, `dev env`, `run`, `export`, `dump`, `diff`, `doctor`
|
|
13
|
-
- advanced tooling: `codegen`, `watch`, `migrate`, `drift`, `vault`
|
|
11
|
+
- data operations: `read`, `value`, `secret`, `define`, `list`, `promote`
|
|
12
|
+
- workflows: `build env`, `dev env`, `run`, `export`, `dump`, `diff`, `doctor`, `ui`
|
|
13
|
+
- advanced tooling: `codegen`, `watch`, `migrate`, `drift`, `vault`, `cache`
|
|
14
|
+
- help and metadata: `help`, `help-ai`, `version`
|
|
14
15
|
|
|
15
16
|
See the individual command pages in this section.
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: cnos list
|
|
3
|
+
description: List resolved config entries across one namespace or the full graph.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# cnos list
|
|
7
|
+
|
|
8
|
+
`cnos list` gives you a resolved view of stored config, promoted output, and namespace-specific data.
|
|
9
|
+
|
|
10
|
+
## Usage
|
|
11
|
+
|
|
12
|
+
```bash
|
|
13
|
+
cnos list [<namespace>|all] [--prefix <path>] [--framework <name>] [--workspace <id>] [--profile <name>]
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
## Examples
|
|
17
|
+
|
|
18
|
+
```bash
|
|
19
|
+
cnos list
|
|
20
|
+
cnos list value --prefix app.
|
|
21
|
+
cnos list flags
|
|
22
|
+
cnos list public --framework vite
|
|
23
|
+
```
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: cnos profile
|
|
3
|
+
description: Create, list, select, and delete explicit profile overlays.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# cnos profile
|
|
7
|
+
|
|
8
|
+
Profiles model environment overlays such as `local`, `stage`, and `prod`.
|
|
9
|
+
|
|
10
|
+
## Usage
|
|
11
|
+
|
|
12
|
+
```bash
|
|
13
|
+
cnos profile [create <name> | list | use <name> | delete <name>] [options] [--root <path>] [--json]
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
## Examples
|
|
17
|
+
|
|
18
|
+
```bash
|
|
19
|
+
cnos profile create stage
|
|
20
|
+
cnos profile create isolated --no-inherit
|
|
21
|
+
cnos profile list
|
|
22
|
+
cnos profile use stage
|
|
23
|
+
```
|
package/docs/cli/run.mdx
CHANGED
|
@@ -12,3 +12,7 @@ cnos run -- node server.js
|
|
|
12
12
|
cnos run --profile stage -- pnpm build
|
|
13
13
|
cnos run --auth -- node server.js
|
|
14
14
|
```
|
|
15
|
+
|
|
16
|
+
Private runs inject explicit `envMapping` entries into the child process, including mapped `secret.*` keys when CNOS can authenticate them. `--public` strips that down to promoted public values only.
|
|
17
|
+
|
|
18
|
+
Use `--auth` when the child process also bootstraps the CNOS runtime from `__CNOS_GRAPH__` and should receive an encrypted pre-resolved secret payload instead of re-authenticating on first secret read.
|
package/docs/cli/ui.mdx
ADDED
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: cnos ui
|
|
3
|
+
description: Launch the local CNOS UI for browsing config state and provenance.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# cnos ui
|
|
7
|
+
|
|
8
|
+
```bash
|
|
9
|
+
cnos ui
|
|
10
|
+
cnos ui --port 4400 --api-port 4401
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
`cnos ui` starts two local services:
|
|
14
|
+
|
|
15
|
+
- a CNOS API server that reads the active workspace and profile
|
|
16
|
+
- a Vite + React + Tailwind UI that renders those surfaces in the browser
|
|
17
|
+
|
|
18
|
+
Use it when you want a faster adoption path than raw CLI output for:
|
|
19
|
+
|
|
20
|
+
- value and meta browsing
|
|
21
|
+
- secret listing with masking intact
|
|
22
|
+
- env mapping review
|
|
23
|
+
- public promotion review
|
|
24
|
+
- inspect/provenance tracing
|
|
25
|
+
|
|
26
|
+
Workspace and profile switching now happen inside the UI itself.
|
|
27
|
+
|
|
28
|
+
## Flags
|
|
29
|
+
|
|
30
|
+
| Flag | Description |
|
|
31
|
+
|------|-------------|
|
|
32
|
+
| `--host` | Host for the Vite UI server. Defaults to `127.0.0.1`. |
|
|
33
|
+
| `--port` | Port for the Vite UI server. Defaults to `4310`. |
|
|
34
|
+
| `--api-port` | Port for the CNOS API server. Defaults to `4311`. |
|
|
35
|
+
| `--workspace` | Override the active workspace. |
|
|
36
|
+
| `--profile` | Override the active profile. |
|
|
37
|
+
|
|
38
|
+
## Notes
|
|
39
|
+
|
|
40
|
+
- The UI is read-only in this first cut.
|
|
41
|
+
- Secret keys stay masked in the browser.
|
|
42
|
+
- Use `cnos inspect` or `cnos read --reveal` when you need terminal-first detail.
|
package/docs/cli/use.mdx
ADDED
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: cnos use
|
|
3
|
+
description: Persist repo-local CLI defaults such as workspace, profile, and global root.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# cnos use
|
|
7
|
+
|
|
8
|
+
`cnos use` reads or writes the repo-local CLI context stored in `.cnos-workspace.yml`.
|
|
9
|
+
|
|
10
|
+
## Usage
|
|
11
|
+
|
|
12
|
+
```bash
|
|
13
|
+
cnos use [show] [--workspace <id>] [--profile <name>] [--global-root <path>] [--root <path>] [--json]
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
## Examples
|
|
17
|
+
|
|
18
|
+
```bash
|
|
19
|
+
cnos use show
|
|
20
|
+
cnos use --workspace api --profile stage
|
|
21
|
+
cnos use --global-root ~/.cnos
|
|
22
|
+
```
|
package/docs/cli/vault.mdx
CHANGED
|
@@ -13,4 +13,6 @@ cnos vault logout default
|
|
|
13
13
|
cnos vault remove default
|
|
14
14
|
```
|
|
15
15
|
|
|
16
|
-
For local vaults, `cnos vault create <name>` initializes the encrypted keystore immediately. CNOS prompts for a passphrase if one is not already available through `CNOS_SECRET_PASSPHRASE_<VAULT>`, `CNOS_SECRET_PASSPHRASE`, or the OS keychain.
|
|
16
|
+
For local vaults, `cnos vault create <name>` initializes the encrypted keystore immediately. CNOS prompts for a passphrase if one is not already available through `CNOS_SECRET_PASSPHRASE_<VAULT>`, `CNOS_SECRET_PASSPHRASE`, or the OS keychain.
|
|
17
|
+
|
|
18
|
+
`cnos vault auth <name>` re-authenticates an existing vault and fails on wrong credentials. Successful auth writes a derived session key under `~/.cnos/secrets/sessions`, so later CNOS commands can reuse it across shells until you run `cnos vault logout <name>` or `cnos vault logout --all`. With `--store-keychain`, CNOS also stores the derived key in the OS keychain.
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: cnos version
|
|
3
|
+
description: Print the installed CNOS CLI version.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# cnos version
|
|
7
|
+
|
|
8
|
+
Use this command when you need the installed `@kitsy/cnos-cli` version string.
|
|
9
|
+
|
|
10
|
+
## Usage
|
|
11
|
+
|
|
12
|
+
```bash
|
|
13
|
+
cnos version
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
## Examples
|
|
17
|
+
|
|
18
|
+
```bash
|
|
19
|
+
cnos version
|
|
20
|
+
cnos --version
|
|
21
|
+
```
|
package/docs/guides/profiles.mdx
CHANGED
|
@@ -11,7 +11,7 @@ Profiles are explicit overlays, not implicit defaults.
|
|
|
11
11
|
cnos profile create stage
|
|
12
12
|
cnos use --profile stage
|
|
13
13
|
cnos value set app.apiBaseUrl https://api.stage
|
|
14
|
-
cnos diff
|
|
14
|
+
cnos diff local stage
|
|
15
15
|
```
|
|
16
16
|
|
|
17
17
|
Profiles inherit values from `base` by default. For a clean profile with no base fallback:
|
|
@@ -22,7 +22,7 @@ Derived surfaces:
|
|
|
22
22
|
Custom data namespaces can be:
|
|
23
23
|
|
|
24
24
|
- read at runtime with `cnos('flags.upi_enabled')`
|
|
25
|
-
- written through the CLI with `cnos
|
|
25
|
+
- written through the CLI with `cnos define value flags.upi_enabled false` or namespace-specific commands where supported
|
|
26
26
|
- promoted to `public.*` when the namespace is `shareable: true`
|
|
27
27
|
- exported through `envMapping.explicit`
|
|
28
28
|
|
|
@@ -11,4 +11,5 @@ CNOS secret rules:
|
|
|
11
11
|
- local vault material is encrypted outside the repo
|
|
12
12
|
- reads are masked by default
|
|
13
13
|
- browser and public outputs never expose `secret.*`
|
|
14
|
-
- `vault auth`
|
|
14
|
+
- `vault auth` caches a reusable derived session key under `~/.cnos/secrets/sessions` until `cnos vault logout`
|
|
15
|
+
- `--store-keychain` adds an OS keychain auth source that works across shells
|
package/manifest.yml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
product: cnos
|
|
2
2
|
title: CNOS Documentation
|
|
3
3
|
tagline: Configuration orchestration for apps, monorepos, and deployment pipelines
|
|
4
|
-
version: "1.8.
|
|
4
|
+
version: "1.8.4"
|
|
5
5
|
|
|
6
6
|
sidebar:
|
|
7
7
|
- group: Getting Started
|
|
@@ -55,12 +55,20 @@ sidebar:
|
|
|
55
55
|
label: cnos init
|
|
56
56
|
- path: cli/onboard
|
|
57
57
|
label: cnos onboard
|
|
58
|
+
- path: cli/use
|
|
59
|
+
label: cnos use
|
|
60
|
+
- path: cli/profile
|
|
61
|
+
label: cnos profile
|
|
58
62
|
- path: cli/workspace
|
|
59
63
|
label: cnos workspace
|
|
60
64
|
- path: cli/value
|
|
61
65
|
label: cnos value
|
|
62
66
|
- path: cli/secret
|
|
63
67
|
label: cnos secret
|
|
68
|
+
- path: cli/define
|
|
69
|
+
label: cnos define
|
|
70
|
+
- path: cli/list
|
|
71
|
+
label: cnos list
|
|
64
72
|
- path: cli/read
|
|
65
73
|
label: cnos read
|
|
66
74
|
- path: cli/inspect
|
|
@@ -83,6 +91,8 @@ sidebar:
|
|
|
83
91
|
label: cnos dump
|
|
84
92
|
- path: cli/doctor
|
|
85
93
|
label: cnos doctor
|
|
94
|
+
- path: cli/ui
|
|
95
|
+
label: cnos ui
|
|
86
96
|
- path: cli/promote
|
|
87
97
|
label: cnos promote
|
|
88
98
|
- path: cli/vault
|
|
@@ -95,6 +105,12 @@ sidebar:
|
|
|
95
105
|
label: cnos migrate
|
|
96
106
|
- path: cli/drift
|
|
97
107
|
label: cnos drift
|
|
108
|
+
- path: cli/help
|
|
109
|
+
label: cnos help
|
|
110
|
+
- path: cli/help-ai
|
|
111
|
+
label: cnos help-ai
|
|
112
|
+
- path: cli/version
|
|
113
|
+
label: cnos version
|
|
98
114
|
|
|
99
115
|
- group: API Reference
|
|
100
116
|
collapsed: true
|