@gadicc/loom 1.32.0 → 1.33.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 +11 -4
- package/esm/src/cli/mod.d.ts +16 -0
- package/esm/src/cli/mod.d.ts.map +1 -1
- package/esm/src/cli/mod.js +505 -24
- package/package.json +2 -2
- package/script/src/cli/mod.d.ts +16 -0
- package/script/src/cli/mod.d.ts.map +1 -1
- package/script/src/cli/mod.js +504 -22
- package/skills/loom-files/SKILL.md +28 -5
|
@@ -45,7 +45,27 @@ Use this skill when working on the shared files feature from a consuming app.
|
|
|
45
45
|
row.
|
|
46
46
|
- Keep upload UI dependencies app-local. Loom helpers should remain headless.
|
|
47
47
|
|
|
48
|
-
##
|
|
48
|
+
## Local S3 storage and Cloudflare R2
|
|
49
|
+
|
|
50
|
+
- After `loom add files`, run `loom files local setup` for a local MinIO server.
|
|
51
|
+
This works before R2 or Vercel setup. It looks for `mcli` or `mc`, tries
|
|
52
|
+
`http://127.0.0.1:9000` and the default MinIO admin credentials, then prompts
|
|
53
|
+
for an endpoint and admin credentials if needed. Set `MINIO_ROOT_USER` and
|
|
54
|
+
`MINIO_ROOT_PASSWORD` in the command environment for non-interactive setup;
|
|
55
|
+
Loom never writes those admin credentials to the app.
|
|
56
|
+
- Setup creates or reuses `<project>-dev`, issues a new MinIO access key
|
|
57
|
+
restricted to read/write operations on that bucket, verifies it with a
|
|
58
|
+
temporary object, and writes canonical `FILES_S3_*` settings to gitignored
|
|
59
|
+
`.env.local`. It reuses a working existing key and never replaces an
|
|
60
|
+
incomplete or invalid credential pair. Use `--local-endpoint` and
|
|
61
|
+
`--local-bucket` when defaults differ.
|
|
62
|
+
- `loom check` checks the local Files env values when the S3 adapter is active
|
|
63
|
+
and warns after `loom add files` while the generated storage stub remains.
|
|
64
|
+
`loom files local check` additionally verifies the bucket through the MinIO
|
|
65
|
+
client. `loom check --production` does not require a developer's `.env.local`.
|
|
66
|
+
- Other S3-compatible services can use the same `FILES_S3_*` variables and an
|
|
67
|
+
app-owned credential provisioning flow. MinIO-specific key creation uses its
|
|
68
|
+
admin API and should not be assumed to work on other services.
|
|
49
69
|
|
|
50
70
|
- Run `loom files r2 setup --account-id <id>` after activating Files. Require
|
|
51
71
|
explicit account selection when Wrangler exposes multiple Cloudflare accounts;
|
|
@@ -72,10 +92,11 @@ Use this skill when working on the shared files feature from a consuming app.
|
|
|
72
92
|
configured bucket or buckets. Use `--configure-secrets` to let Vercel prompt
|
|
73
93
|
for missing Production/Preview values without exposing them to Loom. Never
|
|
74
94
|
copy credentials into Vercel Development or commit them to the repository.
|
|
75
|
-
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
95
|
+
- R2 setup writes non-secret local MinIO defaults when local storage is enabled;
|
|
96
|
+
finish local key creation with `loom files local setup`. Preserve existing
|
|
97
|
+
canonical credentials and unrelated env entries. On Arch, the MinIO client
|
|
98
|
+
executable is `mcli`, from the `minio-client` package. Use
|
|
99
|
+
`--local-provider r2 --local-bucket <name>` only when shared dev files are
|
|
79
100
|
intentional, or `--local-provider none` when storage is managed separately.
|
|
80
101
|
- Setup is rerunnable and reuses existing buckets. Use `--repair` only for
|
|
81
102
|
reviewed non-secret drift; do not delete buckets or rotate credentials as a
|
|
@@ -96,6 +117,8 @@ Use this skill when working on the shared files feature from a consuming app.
|
|
|
96
117
|
## Verification
|
|
97
118
|
|
|
98
119
|
- Run `loom check` after changing files wiring.
|
|
120
|
+
- Run `loom files local check` after local setup to verify the configured bucket
|
|
121
|
+
and credentials.
|
|
99
122
|
- Run `loom files r2 check` after provider setup, or `loom check --network` to
|
|
100
123
|
include the same remote account, bucket, privacy, Vercel scope, and local
|
|
101
124
|
MinIO checks with the rest of the project.
|