create-kumiko-app 0.334.0 → 0.336.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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "create-kumiko-app",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.336.0",
|
|
4
4
|
"description": "`bun create kumiko-app <name>` — scaffold a new Kumiko app with an interactive feature picker.",
|
|
5
5
|
"license": "BUSL-1.1",
|
|
6
6
|
"author": "Marc Frost <marc@cosmicdriftgamestudio.com>",
|
|
@@ -27,10 +27,10 @@
|
|
|
27
27
|
}
|
|
28
28
|
},
|
|
29
29
|
"dependencies": {
|
|
30
|
-
"@cosmicdrift/kumiko-dev-server": "0.
|
|
31
|
-
"@cosmicdrift/kumiko-framework": "0.
|
|
32
|
-
"@cosmicdrift/kumiko-server-runtime": "0.
|
|
33
|
-
"@cosmicdrift/kumiko-testing": "0.
|
|
30
|
+
"@cosmicdrift/kumiko-dev-server": "0.336.0",
|
|
31
|
+
"@cosmicdrift/kumiko-framework": "0.336.0",
|
|
32
|
+
"@cosmicdrift/kumiko-server-runtime": "0.336.0",
|
|
33
|
+
"@cosmicdrift/kumiko-testing": "0.336.0",
|
|
34
34
|
"@inquirer/core": "^10.0.0",
|
|
35
35
|
"@inquirer/prompts": "^7.4.0"
|
|
36
36
|
},
|
|
@@ -128,7 +128,7 @@ describe("--yes resolved set through runProdApp's PII boot gate (issue-2330 regr
|
|
|
128
128
|
);
|
|
129
129
|
});
|
|
130
130
|
|
|
131
|
-
test("requireKmsWiring
|
|
131
|
+
test("requireKmsWiring throws the required-trio error when the trio is empty", () => {
|
|
132
132
|
expect(() =>
|
|
133
133
|
requireKmsWiring(
|
|
134
134
|
{},
|
|
@@ -137,7 +137,9 @@ describe("--yes resolved set through runProdApp's PII boot gate (issue-2330 regr
|
|
|
137
137
|
plaintextReason: "should-not-fallback",
|
|
138
138
|
},
|
|
139
139
|
),
|
|
140
|
-
).toThrow(
|
|
140
|
+
).toThrow(
|
|
141
|
+
"[test] PLATFORM_KEK / SUBJECT_KEYS_DATABASE_URL / KUMIKO_BLIND_INDEX_KEY are required here",
|
|
142
|
+
);
|
|
141
143
|
});
|
|
142
144
|
|
|
143
145
|
test("with resolveKmsWiring's fallback (generated bin/main.ts non-prod path), boot succeeds", async () => {
|
|
@@ -236,5 +238,44 @@ describe("generated bin/main.ts actually boots (issue-2330 regression, real subp
|
|
|
236
238
|
expect(code, `stdout:\n${stdout}\nstderr:\n${stderr}`).toBe(0);
|
|
237
239
|
expect(`${stdout}${stderr}`).not.toContain("BOOT ABORTED");
|
|
238
240
|
expect(stdout).toContain("boot validation OK");
|
|
241
|
+
// The scaffold no longer warns itself; the plaintext path must still be loud via the boot gate.
|
|
242
|
+
expect(`${stdout}${stderr}`).toContain("stored in PLAINTEXT");
|
|
243
|
+
}, 30_000);
|
|
244
|
+
|
|
245
|
+
test("NODE_ENV=production with an empty KMS trio aborts the generated bin/main.ts", async () => {
|
|
246
|
+
mkdirSync(FIXTURE_ROOT, { recursive: true });
|
|
247
|
+
const cwd = mkdtempSync(join(FIXTURE_ROOT, "boot-prod-"));
|
|
248
|
+
createdDirs.push(cwd);
|
|
249
|
+
|
|
250
|
+
const exitCode = await runCreate({ name: "boot-prod-fixture", yes: true, cwd, log: () => {} });
|
|
251
|
+
expect(exitCode).toBe(0);
|
|
252
|
+
|
|
253
|
+
const proc = Bun.spawn({
|
|
254
|
+
cmd: ["bun", "bin/main.ts"],
|
|
255
|
+
cwd: join(cwd, "boot-prod-fixture"),
|
|
256
|
+
env: {
|
|
257
|
+
...process.env,
|
|
258
|
+
NODE_ENV: "production",
|
|
259
|
+
KUMIKO_DRY_RUN_ENV: "boot",
|
|
260
|
+
JWT_SECRET: "a".repeat(32),
|
|
261
|
+
KUMIKO_SECRETS_MASTER_KEY_V1: Buffer.alloc(32, 7).toString("base64"),
|
|
262
|
+
DATABASE_URL: "postgres://dummy:dummy@127.0.0.1:1/dummy",
|
|
263
|
+
REDIS_URL: "redis://127.0.0.1:1",
|
|
264
|
+
PLATFORM_KEK: "",
|
|
265
|
+
SUBJECT_KEYS_DATABASE_URL: "",
|
|
266
|
+
KUMIKO_BLIND_INDEX_KEY: "",
|
|
267
|
+
},
|
|
268
|
+
stdout: "pipe",
|
|
269
|
+
stderr: "pipe",
|
|
270
|
+
});
|
|
271
|
+
const [stdout, stderr, code] = await Promise.all([
|
|
272
|
+
new Response(proc.stdout).text(),
|
|
273
|
+
new Response(proc.stderr).text(),
|
|
274
|
+
proc.exited,
|
|
275
|
+
]);
|
|
276
|
+
|
|
277
|
+
expect(code, `stdout:\n${stdout}\nstderr:\n${stderr}`).not.toBe(0);
|
|
278
|
+
expect(`${stdout}${stderr}`).toContain("PLATFORM_KEK / SUBJECT_KEYS_DATABASE_URL");
|
|
279
|
+
expect(`${stdout}${stderr}`).toContain("are required here");
|
|
239
280
|
}, 30_000);
|
|
240
281
|
});
|