create-op-node 0.1.0 → 0.2.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 +55 -1
- package/dist/cli.js +498 -198
- package/dist/cli.js.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -24,7 +24,61 @@ npx create-op-node bootstrap
|
|
|
24
24
|
|
|
25
25
|
Configures macOS power settings, installs Homebrew + the CLI tool list, sets up Docker Desktop + Tailscale + Ollama, clones the node repo you created, materializes the pgsodium key from 1Password, writes the LaunchAgent plist, logs into ghcr.io, pulls + warms the LLM model, and finally `docker compose pull && up -d` brings the whole stack online. Health-check loop waits until all 10 containers are `(healthy)`.
|
|
26
26
|
|
|
27
|
-
|
|
27
|
+
## Resetting the Studio
|
|
28
|
+
|
|
29
|
+
To start over (e.g. before rerunning `bootstrap` against a different
|
|
30
|
+
region, or after a misconfiguration), reverse the Studio-side state:
|
|
31
|
+
|
|
32
|
+
```bash
|
|
33
|
+
npx create-op-node reset --region us-ca
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
Three phases run in reverse-bootstrap order. By default volumes are
|
|
37
|
+
preserved — the database survives so you can bring the stack back up
|
|
38
|
+
with `bootstrap` without losing data.
|
|
39
|
+
|
|
40
|
+
1. **Stop the stack** — `docker compose down`. Pass `--wipe-data` to
|
|
41
|
+
add `-v` (destroys named volumes including the database). The wipe
|
|
42
|
+
mode requires retyping the region label as confirmation — and the
|
|
43
|
+
prompt deliberately doesn't pre-fill the answer, so you have to type
|
|
44
|
+
it from memory. `y` won't do it.
|
|
45
|
+
2. **Unload + remove the LaunchAgent** — `launchctl unload` then `rm`
|
|
46
|
+
the plist and the pgsodium key file. `--keep-key-file` leaves the
|
|
47
|
+
key in place as a belt-and-suspenders backup before a wipe-data run.
|
|
48
|
+
3. **`docker logout`** — clears the registry-credentials store entry
|
|
49
|
+
for `ghcr.io` (or override with `--registry`). This only clears the
|
|
50
|
+
store entry; if your credential helper caches the token elsewhere
|
|
51
|
+
(or `~/.docker/config.json` has stale entries from another host),
|
|
52
|
+
those need separate cleanup.
|
|
53
|
+
|
|
54
|
+
Reset does **not** touch cloud-side state: the Cloudflare resources,
|
|
55
|
+
the GitHub repo, the TFC workspace, and the 1Password items remain.
|
|
56
|
+
`init` is idempotent against existing cloud setup, so re-running it
|
|
57
|
+
won't duplicate anything.
|
|
58
|
+
|
|
59
|
+
Useful flags:
|
|
60
|
+
|
|
61
|
+
- `--dry-run` — print the plan without acting. Phases that would run
|
|
62
|
+
show with a `?` icon; phases that are skipped show with `·`.
|
|
63
|
+
- `--skip-stack` / `--skip-launch-agent` / `--skip-docker-logout` —
|
|
64
|
+
surgical resets when only one piece needs cleaning.
|
|
65
|
+
- `--no-remove-orphans` — drop `--remove-orphans` from `compose down`.
|
|
66
|
+
Useful when you ran bootstrap with a custom `--compose-file` set and
|
|
67
|
+
reset without it.
|
|
68
|
+
- `--repo-dir <path>` — explicit path to the cloned node repo when
|
|
69
|
+
reset is run from outside the checkout. Passing a path that doesn't
|
|
70
|
+
look like a node repo is a hard error, not a silent skip.
|
|
71
|
+
- `--registry <reg>` — log out of a registry other than `ghcr.io`.
|
|
72
|
+
|
|
73
|
+
```bash
|
|
74
|
+
# Try-before-you-buy: preview every step.
|
|
75
|
+
npx create-op-node reset --region us-ca --dry-run
|
|
76
|
+
|
|
77
|
+
# Nuke from orbit: containers + volumes + LaunchAgent + ghcr credentials.
|
|
78
|
+
npx create-op-node reset --region us-ca --wipe-data
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
## Verifying a live node
|
|
28
82
|
|
|
29
83
|
```bash
|
|
30
84
|
npx create-op-node verify --domain your-domain.example
|