@ts-cloud/core 0.9.2 → 0.9.4

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.
Files changed (3) hide show
  1. package/dist/index.js +6419 -47043
  2. package/dist/types.d.ts +28 -1
  3. package/package.json +2 -2
package/dist/types.d.ts CHANGED
@@ -14,7 +14,34 @@ export interface CloudProviderConfig {
14
14
  * this project's sites, and adds its own additive rpx `sites.d/<slug>.json`
15
15
  * fragment + DNS — never touching the owner's box lifecycle, firewall, or other
16
16
  * tenants. The owner provisions and manages the shared box; attachers only
17
- * deploy onto it. Requires read access via the same `HCLOUD_TOKEN`.
17
+ * deploy onto it.
18
+ *
19
+ * ## This widens what your CI credential can reach
20
+ *
21
+ * Attaching resolves the host by listing the provider's servers with THIS
22
+ * project's own token, so the owner's box has to be visible to it, which means
23
+ * both projects live in the same provider project. On Hetzner that is the whole
24
+ * story: Cloud API tokens are scoped to a project with Read or Read & Write and
25
+ * offer no per-resource scoping, and a deploy needs write. So the moment this is
26
+ * set, this project's CI token can modify and delete EVERY server in that
27
+ * provider project, not just the box it deploys to.
28
+ *
29
+ * Concretely, three apps that each owned one box become three pipelines that
30
+ * each reach all three, plus anything else in the project. That is a real change
31
+ * in blast radius: a compromised CI run or a mistargeted teardown now reaches
32
+ * production systems belonging to unrelated apps.
33
+ *
34
+ * **Per-project isolation and attaching are mutually exclusive.** An app kept in
35
+ * its own provider project cannot be attached at all, because its token cannot
36
+ * see the owner's box. Choosing to co-host is choosing to trade credential
37
+ * isolation for a shared box; the reverse trade is equally available, and neither
38
+ * is a default worth stumbling into.
39
+ *
40
+ * `describeCredentialReach()` reports what a given token can actually reach, so
41
+ * the radius can be shown before an attach is approved rather than discovered
42
+ * afterwards.
43
+ *
44
+ * @see https://github.com/stacksjs/ts-cloud/issues/169
18
45
  */
19
46
  attachTo?: string;
20
47
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@ts-cloud/core",
3
3
  "type": "module",
4
- "version": "0.9.2",
4
+ "version": "0.9.4",
5
5
  "description": "Core CloudFormation generation library for ts-cloud",
6
6
  "author": "Chris Breuer <chris@stacksjs.com>",
7
7
  "license": "MIT",
@@ -31,7 +31,7 @@
31
31
  "typecheck": "tsc --noEmit"
32
32
  },
33
33
  "dependencies": {
34
- "@ts-cloud/aws-types": "0.9.2"
34
+ "@ts-cloud/aws-types": "0.9.4"
35
35
  },
36
36
  "devDependencies": {
37
37
  "typescript": "^7.0.2"