@tdk-landscape/tdk-cli-core 1.3.59 → 1.3.61

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/CHANGELOG.md CHANGED
@@ -4,6 +4,14 @@ Notable changes to the `tdk` CLI. Versions match [npm](https://www.npmjs.com/pac
4
4
 
5
5
  ## Unreleased
6
6
 
7
+ - `tdk doctor` and `tdk up` no longer report free host ports (80, 443, 5432) as "taken" on Linux. The port check bound `0.0.0.0` and `127.0.0.1` at the same time, and on Linux the second bind collided with our own first probe. It now probes them one after the other, which still catches a loopback-only Postgres on macOS. Found by the nightly clean-machine quickstart run.
8
+
9
+ ## 1.3.60 (2026-09-27)
10
+
11
+ - Backends and workers scaffolded by `tdk resource` get a `start` script, and `@types/bun` is pinned instead of `latest`. Before, `tdk doctor` failed on every new service. Found by the clean-machine quickstart run.
12
+
13
+ ## 1.3.59 (2026-09-27)
14
+
7
15
  - `tdk doctor` no longer fails every fresh project with "Generated Dockerfiles reference missing project runtime assets: prisma-runtime-relink.sh, migrate.sh". Those two scripts were never shipped or used by generated Dockerfiles; doctor now checks the scripts TDK ships plus whatever generated Dockerfiles actually copy. Found by the new clean-machine quickstart run.
8
16
 
9
17
  ## 1.3.58 (2026-09-27)
@@ -73,6 +73,8 @@ export function createPackageJson(name, type) {
73
73
  scripts: {
74
74
  dev: isFrontend ? "vite" : "bun run --watch src/index.ts",
75
75
  build: isFrontend ? "tsc && vite build" : "tsc",
76
+ // Backends and workers run `start` in their production image; doctor checks for it.
77
+ ...(isFrontend ? {} : { start: "bun run dist/index.js" }),
76
78
  test: "vitest",
77
79
  lint: "biome check .",
78
80
  "lint:fix": "biome check . --write",
@@ -81,7 +83,7 @@ export function createPackageJson(name, type) {
81
83
  ...(isFrontend ? {} : { hono: "^4.0.0" }),
82
84
  },
83
85
  devDependencies: {
84
- "@types/bun": "latest",
86
+ "@types/bun": "^1.4.2",
85
87
  typescript: "^7.0.2",
86
88
  vitest: "^5.0.0",
87
89
  "@biomejs/biome": "^2.5.13",
@@ -336,17 +336,18 @@ function probeAddress(port, host) {
336
336
  });
337
337
  }
338
338
  /**
339
- * Probes both the wildcard and loopback address: a Homebrew Postgres listens on
340
- * 127.0.0.1 only, which a wildcard bind alone doesn't detect.
339
+ * Probes both the wildcard and loopback address: on macOS, a Homebrew Postgres
340
+ * bound to 127.0.0.1 only is invisible to a wildcard-only bind. Sequential, not
341
+ * concurrent: on Linux, binding 0.0.0.0 and 127.0.0.1 to the same port at the
342
+ * same time makes the second bind fail with EADDRINUSE against *our own first
343
+ * probe*, reporting every free port as taken. Binding 0.0.0.0 first and closing
344
+ * it before trying 127.0.0.1 avoids that self-collision on every platform.
341
345
  */
342
346
  export async function probeHostPort(port) {
343
- const results = await Promise.all([
344
- probeAddress(port, "0.0.0.0"),
345
- probeAddress(port, "127.0.0.1"),
346
- ]);
347
- if (results.includes("in-use"))
348
- return "in-use";
349
- return results.includes("free") ? "free" : "unknown";
347
+ const wildcard = await probeAddress(port, "0.0.0.0");
348
+ if (wildcard !== "free")
349
+ return wildcard;
350
+ return probeAddress(port, "127.0.0.1");
350
351
  }
351
352
  /**
352
353
  * Catches host ports taken by something other than this project's containers,
package/cli/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "tdk-cli-internal",
3
3
  "private": true,
4
- "version": "1.3.59",
4
+ "version": "1.3.61",
5
5
  "description": "TDK CLI - Tilt Development Kit command line interface",
6
6
  "keywords": [
7
7
  "tdk",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tdk-landscape/tdk-cli-core",
3
- "version": "1.3.59",
3
+ "version": "1.3.61",
4
4
  "description": "Run 100 microservices on a 16 GB laptop without Kubernetes. Scaffold services and run them locally with hot reload, built on Tilt.",
5
5
  "homepage": "https://tdk-landscape.github.io/tdk-website",
6
6
  "repository": {