Skip to content

Commit 848343e

Browse files
authored
docs: prepare v0.1.0 release documentation (#50)
Add comprehensive v0.1.0 release preparation including CLI reference, release notes, and updated getting started guides. This commit finalizes documentation for the first public release. Changes: - Add CLI commands reference (docs/cli/commands.md) with server runtime, key management, and client management commands - Add v0.1.0 release notes (docs/releases/v0.1.0.md) with API surface, operational notes, and known limitations - Update Docker guide with pinned v0.1.0 image tag and first-client bootstrap flow using create-client command - Update local development guide with create-client bootstrap flow - Clarify OpenAPI coverage scope in versioning policy and docs index - Update root README and docs index with CLI reference and release notes links - Add create-client prerequisite note to curl examples - Update CHANGELOG with v0.1.0 release prep activities
1 parent 8b099e8 commit 848343e

9 files changed

Lines changed: 284 additions & 13 deletions

File tree

README.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,11 @@ Secrets is inspired by **HashiCorp Vault** ❤️, but it is intentionally **muc
1313
The default way to run Secrets is the published Docker image:
1414

1515
```bash
16-
docker pull allisson/secrets:latest
16+
docker pull allisson/secrets:v0.1.0
1717
```
1818

19+
Use pinned tags for reproducible setups. `latest` is also available for fast iteration.
20+
1921
Then follow the Docker setup guide in [docs/getting-started/docker.md](docs/getting-started/docker.md).
2022

2123
⚠️ After rotating a master key or KEK, restart API server instances so they load the updated key material.
@@ -33,6 +35,8 @@ Then follow the Docker setup guide in [docs/getting-started/docker.md](docs/gett
3335
- 💻 **Getting started (local)**: [docs/getting-started/local-development.md](docs/getting-started/local-development.md)
3436
- 🧰 **Troubleshooting**: [docs/getting-started/troubleshooting.md](docs/getting-started/troubleshooting.md)
3537
-**Smoke test script**: [docs/getting-started/smoke-test.md](docs/getting-started/smoke-test.md)
38+
- 🧪 **CLI commands reference**: [docs/cli/commands.md](docs/cli/commands.md)
39+
- 🚀 **v0.1.0 release notes**: [docs/releases/v0.1.0.md](docs/releases/v0.1.0.md)
3640

3741
- **By Topic**
3842
- ⚙️ **Environment variables**: [docs/configuration/environment-variables.md](docs/configuration/environment-variables.md)

docs/CHANGELOG.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,16 @@
22

33
> Last updated: 2026-02-14
44
5+
## 2026-02-14 (docs v2 - v0.1.0 release prep)
6+
7+
- Added first-client bootstrap flow to Docker and local development guides using `create-client`
8+
- Added CLI reference page with runtime, key management, and client management commands
9+
- Linked CLI docs and release notes from root README and docs index
10+
- Switched Docker release guide examples to pinned image tag `allisson/secrets:v0.1.0`
11+
- Added explicit OpenAPI coverage note: `docs/openapi.yaml` is baseline subset for common flows
12+
- Clarified API v1 compatibility expectations relative to pre-1.0 app releases
13+
- Added release notes page: `docs/releases/v0.1.0.md`
14+
515
## 2026-02-14 (docs v1)
616

717
- Split large root README into focused docs under `docs/`

docs/README.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ Welcome to the full documentation for Secrets. Pick a path and dive in 🚀
1010
- 💻 [getting-started/local-development.md](getting-started/local-development.md)
1111
- 🧰 [getting-started/troubleshooting.md](getting-started/troubleshooting.md)
1212
-[getting-started/smoke-test.md](getting-started/smoke-test.md)
13+
- 🧪 [cli/commands.md](cli/commands.md)
1314

1415
## 🛣️ First-Time Operator Path
1516

@@ -52,6 +53,15 @@ Welcome to the full documentation for Secrets. Pick a path and dive in 🚀
5253
- 🧩 [api/versioning-policy.md](api/versioning-policy.md)
5354
- 📄 [openapi.yaml](openapi.yaml)
5455

56+
OpenAPI scope note:
57+
58+
- `openapi.yaml` is a baseline subset for common API flows in `v0.1.0`
59+
- Full endpoint behavior is documented in the endpoint pages under `docs/api/`
60+
61+
## 🚀 Releases
62+
63+
- 📦 [releases/v0.1.0.md](releases/v0.1.0.md)
64+
5565
## 🧠 ADRs
5666

5767
- 🧾 [adr/0001-envelope-encryption-model.md](adr/0001-envelope-encryption-model.md)

docs/api/versioning-policy.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,18 @@ This page defines compatibility expectations for HTTP API changes.
1111
- Existing endpoint paths and JSON field names are treated as stable unless explicitly deprecated
1212
- OpenAPI source of truth: `docs/openapi.yaml`
1313

14+
## OpenAPI Coverage (v0.1.0)
15+
16+
- `docs/openapi.yaml` is a baseline subset focused on high-traffic/common integration flows
17+
- Endpoint pages in `docs/api/*.md` define full public behavior for covered operations
18+
- Endpoints may exist in runtime before they are expanded in OpenAPI detail
19+
20+
## App Version vs API Version
21+
22+
- Application release `v0.1.0` is pre-1.0 software and may evolve quickly
23+
- API v1 path contract (`/v1/*`) remains the compatibility baseline for consumers
24+
- Breaking API behavior changes require explicit documentation and migration notes
25+
1426
## Breaking Changes
1527

1628
Treat these as breaking:

docs/cli/commands.md

Lines changed: 141 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,141 @@
1+
# 🧪 CLI Commands Reference
2+
3+
> Last updated: 2026-02-14
4+
5+
Use the `app` CLI for server runtime, key management, and client lifecycle operations.
6+
7+
## Binary and Docker forms
8+
9+
Local binary:
10+
11+
```bash
12+
./bin/app <command> [flags]
13+
```
14+
15+
Docker image (v0.1.0):
16+
17+
```bash
18+
docker run --rm --env-file .env allisson/secrets:v0.1.0 <command> [flags]
19+
```
20+
21+
## Core Runtime
22+
23+
### `server`
24+
25+
Starts the HTTP API server.
26+
27+
```bash
28+
./bin/app server
29+
```
30+
31+
### `migrate`
32+
33+
Runs database migrations.
34+
35+
```bash
36+
./bin/app migrate
37+
```
38+
39+
## Key Management
40+
41+
### `create-master-key`
42+
43+
Generates a new 32-byte master key and prints `MASTER_KEYS` / `ACTIVE_MASTER_KEY_ID` values.
44+
45+
Flags:
46+
47+
- `--id`, `-i`: master key ID
48+
49+
```bash
50+
./bin/app create-master-key --id default
51+
```
52+
53+
### `create-kek`
54+
55+
Creates an initial KEK from the active master key.
56+
57+
Flags:
58+
59+
- `--algorithm`, `--alg`: `aes-gcm` (default) or `chacha20-poly1305`
60+
61+
```bash
62+
./bin/app create-kek --algorithm aes-gcm
63+
```
64+
65+
### `rotate-kek`
66+
67+
Rotates KEK to a new version.
68+
69+
Flags:
70+
71+
- `--algorithm`, `--alg`: `aes-gcm` (default) or `chacha20-poly1305`
72+
73+
```bash
74+
./bin/app rotate-kek --algorithm aes-gcm
75+
```
76+
77+
After master key or KEK rotation, restart API server instances so they load updated key material.
78+
79+
## Client Management
80+
81+
### `create-client`
82+
83+
Creates an API client and returns `client_id` plus one-time `secret`.
84+
85+
Flags:
86+
87+
- `--name`, `-n` (required): client name
88+
- `--active`, `-a` (default `true`): whether client can authenticate immediately
89+
- `--policies`, `-p`: JSON array of policy documents (omit to use interactive mode)
90+
- `--format`, `-f`: `text` (default) or `json`
91+
92+
Non-interactive example:
93+
94+
```bash
95+
./bin/app create-client \
96+
--name bootstrap-admin \
97+
--active \
98+
--policies '[{"path":"*","capabilities":["read","write","delete","encrypt","decrypt","rotate"]}]' \
99+
--format json
100+
```
101+
102+
Interactive example:
103+
104+
```bash
105+
./bin/app create-client --name bootstrap-admin
106+
```
107+
108+
### `update-client`
109+
110+
Updates client name, active state, and policies.
111+
112+
Flags:
113+
114+
- `--id`, `-i` (required): client UUID
115+
- `--name`, `-n` (required): client name
116+
- `--active`, `-a` (default `true`): whether client can authenticate
117+
- `--policies`, `-p`: JSON array of policy documents (omit to use interactive mode)
118+
- `--format`, `-f`: `text` (default) or `json`
119+
120+
```bash
121+
./bin/app update-client \
122+
--id <client-uuid> \
123+
--name payments-api \
124+
--active=true \
125+
--policies '[{"path":"/v1/secrets/*","capabilities":["read","encrypt"]}]' \
126+
--format json
127+
```
128+
129+
## Output and Safety Notes
130+
131+
- `create-client` secret is shown once and cannot be retrieved later
132+
- Prefer `--format json` for automation
133+
- Store client secrets in a secure secret manager
134+
- Use least-privilege policies per workload and path
135+
136+
## See also
137+
138+
- [Docker getting started](../getting-started/docker.md)
139+
- [Local development](../getting-started/local-development.md)
140+
- [Authentication API](../api/authentication.md)
141+
- [Policies cookbook](../api/policies.md)

docs/examples/curl.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,9 @@
66

77
End-to-end shell workflow.
88

9+
Need first credentials? Create an API client with `app create-client` first.
10+
See [CLI commands reference](../cli/commands.md).
11+
912
## Bootstrap
1013

1114
Prerequisites:

docs/getting-started/docker.md

Lines changed: 29 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,15 @@
44
55
This is the default way to run Secrets.
66

7+
For release reproducibility, this guide uses the pinned image tag `allisson/secrets:v0.1.0`.
8+
You can use `allisson/secrets:latest` for fast iteration.
9+
710
## ⚡ Quickstart Copy Block
811

912
Use this minimal flow when you just want to get a working instance quickly:
1013

1114
```bash
12-
docker pull allisson/secrets:latest
15+
docker pull allisson/secrets:v0.1.0
1316
docker network create secrets-net || true
1417

1518
docker run -d --name secrets-postgres --network secrets-net \
@@ -18,19 +21,19 @@ docker run -d --name secrets-postgres --network secrets-net \
1821
-e POSTGRES_DB=mydb \
1922
postgres:16-alpine
2023

21-
docker run --rm allisson/secrets:latest create-master-key --id default
24+
docker run --rm allisson/secrets:v0.1.0 create-master-key --id default
2225
# copy generated MASTER_KEYS and ACTIVE_MASTER_KEY_ID into .env
2326

24-
docker run --rm --network secrets-net --env-file .env allisson/secrets:latest migrate
25-
docker run --rm --network secrets-net --env-file .env allisson/secrets:latest create-kek --algorithm aes-gcm
27+
docker run --rm --network secrets-net --env-file .env allisson/secrets:v0.1.0 migrate
28+
docker run --rm --network secrets-net --env-file .env allisson/secrets:v0.1.0 create-kek --algorithm aes-gcm
2629
docker run --rm --name secrets-api --network secrets-net --env-file .env -p 8080:8080 \
27-
allisson/secrets:latest server
30+
allisson/secrets:v0.1.0 server
2831
```
2932

3033
## 1) Pull the image
3134

3235
```bash
33-
docker pull allisson/secrets:latest
36+
docker pull allisson/secrets:v0.1.0
3437
```
3538

3639
## 2) Start PostgreSQL
@@ -48,7 +51,7 @@ docker run -d --name secrets-postgres --network secrets-net \
4851
## 3) Generate a master key
4952

5053
```bash
51-
docker run --rm allisson/secrets:latest create-master-key --id default
54+
docker run --rm allisson/secrets:v0.1.0 create-master-key --id default
5255
```
5356

5457
Copy the generated values into a local `.env` file.
@@ -77,15 +80,15 @@ EOF
7780
## 5) Run migrations and bootstrap KEK
7881

7982
```bash
80-
docker run --rm --network secrets-net --env-file .env allisson/secrets:latest migrate
81-
docker run --rm --network secrets-net --env-file .env allisson/secrets:latest create-kek --algorithm aes-gcm
83+
docker run --rm --network secrets-net --env-file .env allisson/secrets:v0.1.0 migrate
84+
docker run --rm --network secrets-net --env-file .env allisson/secrets:v0.1.0 create-kek --algorithm aes-gcm
8285
```
8386

8487
## 6) Start the API server
8588

8689
```bash
8790
docker run --rm --name secrets-api --network secrets-net --env-file .env -p 8080:8080 \
88-
allisson/secrets:latest server
91+
allisson/secrets:v0.1.0 server
8992
```
9093

9194
## 7) Verify
@@ -100,7 +103,21 @@ Expected:
100103
{"status":"healthy"}
101104
```
102105

103-
## 8) First token + first secret
106+
## 8) Create first client credentials
107+
108+
Use the CLI command to create your first API client and policy set:
109+
110+
```bash
111+
docker run --rm --network secrets-net --env-file .env allisson/secrets:v0.1.0 create-client \
112+
--name bootstrap-admin \
113+
--active \
114+
--policies '[{"path":"*","capabilities":["read","write","delete","encrypt","decrypt","rotate"]}]' \
115+
--format json
116+
```
117+
118+
Save the returned `client_id` and one-time `secret` securely. The secret is shown only once.
119+
120+
## 9) First token + first secret
104121

105122
```bash
106123
curl -X POST http://localhost:8080/v1/token \
@@ -129,3 +146,4 @@ For a full end-to-end check, run `docs/getting-started/smoke-test.sh` (usage in
129146
- [Smoke test](smoke-test.md)
130147
- [Troubleshooting](troubleshooting.md)
131148
- [Environment variables](../configuration/environment-variables.md)
149+
- [CLI commands reference](../cli/commands.md)

docs/getting-started/local-development.md

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,29 @@ DB_CONNECTION_STRING=postgres://user:password@localhost:5432/mydb?sslmode=disabl
5858
./bin/app server
5959
```
6060

61-
## 7) Smoke test
61+
## 7) Create first client credentials
62+
63+
In another terminal, create your first API client and policy set:
64+
65+
```bash
66+
./bin/app create-client \
67+
--name bootstrap-admin \
68+
--active \
69+
--policies '[{"path":"*","capabilities":["read","write","delete","encrypt","decrypt","rotate"]}]' \
70+
--format json
71+
```
72+
73+
Save the returned `client_id` and one-time `secret` securely.
74+
75+
## 8) Issue token
76+
77+
```bash
78+
curl -X POST http://localhost:8080/v1/token \
79+
-H "Content-Type: application/json" \
80+
-d '{"client_id":"<client-id>","client_secret":"<client-secret>"}'
81+
```
82+
83+
## 9) Smoke test
6284

6385
```bash
6486
curl http://localhost:8080/health
@@ -70,3 +92,4 @@ curl http://localhost:8080/health
7092
- [Smoke test](smoke-test.md)
7193
- [Troubleshooting](troubleshooting.md)
7294
- [Testing guide](../development/testing.md)
95+
- [CLI commands reference](../cli/commands.md)

0 commit comments

Comments
 (0)