@vibesdotdev/infra-core 1.0.0-rc.5 → 1.0.0-rc.6
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/dist/deployment-budget.d.ts +319 -0
- package/dist/deployment-budget.d.ts.map +1 -0
- package/dist/deployment-budget.js +659 -0
- package/dist/deployment-budget.js.map +1 -0
- package/dist/deployment-graph.d.ts +182 -0
- package/dist/deployment-graph.d.ts.map +1 -0
- package/dist/deployment-graph.js +685 -0
- package/dist/deployment-graph.js.map +1 -0
- package/dist/index.d.ts +2 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -1
- package/dist/index.js.map +1 -1
- package/dist/infra.plugin.d.ts.map +1 -1
- package/dist/infra.plugin.js +2 -0
- package/dist/infra.plugin.js.map +1 -1
- package/dist/kinds/compute-source.kind.d.ts +21 -4
- package/dist/kinds/compute-source.kind.d.ts.map +1 -1
- package/dist/kinds/compute-source.kind.js +14 -1
- package/dist/kinds/compute-source.kind.js.map +1 -1
- package/dist/kinds/database.kind.d.ts +1 -1
- package/dist/kinds/dns.kind.d.ts +3 -3
- package/dist/kinds/edge-hostname.kind.d.ts +124 -0
- package/dist/kinds/edge-hostname.kind.d.ts.map +1 -0
- package/dist/kinds/edge-hostname.kind.js +87 -0
- package/dist/kinds/edge-hostname.kind.js.map +1 -0
- package/dist/kinds/index.d.ts +2 -2
- package/dist/kinds/index.d.ts.map +1 -1
- package/dist/kinds/index.js +1 -1
- package/dist/kinds/index.js.map +1 -1
- package/dist/kinds/load-balancer.kind.d.ts +4 -4
- package/dist/kinds/sandbox.kind.d.ts +7 -11
- package/dist/kinds/sandbox.kind.d.ts.map +1 -1
- package/dist/kinds/sandbox.kind.js +6 -13
- package/dist/kinds/sandbox.kind.js.map +1 -1
- package/dist/kinds/utilization.kind.d.ts +2 -2
- package/dist/kinds/web-app.kind.d.ts +3 -0
- package/dist/kinds/web-app.kind.d.ts.map +1 -1
- package/dist/schemas/deployment-provider.d.ts +46 -1
- package/dist/schemas/deployment-provider.d.ts.map +1 -1
- package/dist/schemas/deployment-provider.js +15 -2
- package/dist/schemas/deployment-provider.js.map +1 -1
- package/dist/schemas.d.ts +5 -0
- package/dist/schemas.d.ts.map +1 -1
- package/dist/schemas.js +14 -0
- package/dist/schemas.js.map +1 -1
- package/dist/web-app-projection.d.ts +3 -0
- package/dist/web-app-projection.d.ts.map +1 -1
- package/package.json +14 -8
- package/dist/kinds/compute-sources.descriptors.d.ts +0 -45
- package/dist/kinds/compute-sources.descriptors.d.ts.map +0 -1
- package/dist/kinds/compute-sources.descriptors.js +0 -93
- package/dist/kinds/compute-sources.descriptors.js.map +0 -1
|
@@ -1,45 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* The compute sources we actually own, priced from the providers' own lists.
|
|
3
|
-
*
|
|
4
|
-
* These are data, like `training/executor`'s reference descriptors. They exist
|
|
5
|
-
* so `infra/compute-source` stops being a schema with no rows: selection can
|
|
6
|
-
* only be honest about which machine is cheaper if somebody has written down
|
|
7
|
-
* what the machines cost.
|
|
8
|
-
*
|
|
9
|
-
* Every rate here was read from the provider on 2026-09-08 rather than
|
|
10
|
-
* estimated, and the arithmetic is left in the source so the next person can
|
|
11
|
-
* re-derive it instead of trusting a decimal. Deriving DigitalOcean's rate by
|
|
12
|
-
* hand as `$24/month ÷ 730h ÷ 3600s` gives $0.00000913/s, which is 8% under
|
|
13
|
-
* what DigitalOcean actually charges — the monthly price is a cap, not the
|
|
14
|
-
* basis for the hourly rate. That is exactly the kind of quiet error a
|
|
15
|
-
* hand-typed number produces, and the reason `source` and `effectiveAt` are
|
|
16
|
-
* required fields.
|
|
17
|
-
*
|
|
18
|
-
* Capability claims are deliberately conservative. `labels` is empty on both:
|
|
19
|
-
* an overstated capability is how a job that demands `docker` silently lands
|
|
20
|
-
* somewhere without it, and the kind refuses rather than substitutes. Add a
|
|
21
|
-
* label when someone has verified it, not because it is probably true.
|
|
22
|
-
*/
|
|
23
|
-
import type { ComputeSourceDescriptor } from './compute-source.kind.ts';
|
|
24
|
-
/**
|
|
25
|
-
* Cloudflare Containers `standard-4` — what `forge-ci-worker` runs on today
|
|
26
|
-
* (`wrangler.jsonc`, `instance_type: "standard-4"`): 4 vCPU, 12 GiB memory,
|
|
27
|
-
* 20 GB disk.
|
|
28
|
-
*
|
|
29
|
-
* Cloudflare bills memory and disk on PROVISIONED resources and CPU on ACTIVE
|
|
30
|
-
* usage only (a November 2025 pricing change), so the two rates are split.
|
|
31
|
-
* A CI job is CPU-bound almost by definition, so its real cost sits near
|
|
32
|
-
* `usdPerSecond + usdPerSecondCpuActive`; an idle container costs the floor.
|
|
33
|
-
*/
|
|
34
|
-
export declare const cfContainerStandard4: ComputeSourceDescriptor;
|
|
35
|
-
/**
|
|
36
|
-
* DigitalOcean droplet `s-2vcpu-4gb`: 2 vCPU, 4 GiB memory, 80 GB disk.
|
|
37
|
-
*
|
|
38
|
-
* Billed per second with a floor of 60 seconds or $0.01, whichever is higher.
|
|
39
|
-
* At this size 60 seconds is $0.000595, so $0.01 is always the binding floor —
|
|
40
|
-
* which means a 10-second lease and a 16-minute lease cost the same.
|
|
41
|
-
*/
|
|
42
|
-
export declare const doDropletS2vcpu4gb: ComputeSourceDescriptor;
|
|
43
|
-
/** Every compute source we own, cheapest-first ordering left to the selector. */
|
|
44
|
-
export declare const vibesComputeSources: readonly ComputeSourceDescriptor[];
|
|
45
|
-
//# sourceMappingURL=compute-sources.descriptors.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"compute-sources.descriptors.d.ts","sourceRoot":"","sources":["../../src/kinds/compute-sources.descriptors.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,0BAA0B,CAAC;AAexE;;;;;;;;;GASG;AACH,eAAO,MAAM,oBAAoB,EAAE,uBA4BlC,CAAC;AAEF;;;;;;GAMG;AACH,eAAO,MAAM,kBAAkB,EAAE,uBA6BhC,CAAC;AAEF,iFAAiF;AACjF,eAAO,MAAM,mBAAmB,EAAE,SAAS,uBAAuB,EAGjE,CAAC"}
|
|
@@ -1,93 +0,0 @@
|
|
|
1
|
-
/** When these quotes were read from the providers. */
|
|
2
|
-
const QUOTED_AT = '2026-09-08T00:00:00.000Z';
|
|
3
|
-
/**
|
|
4
|
-
* The Forge job contract caps a whole job at 7 days
|
|
5
|
-
* (`MAX_FORGE_ACTIONS_JOB_TIMEOUT_MINUTES`), and neither source imposes a
|
|
6
|
-
* shorter limit of its own that we have measured. This is that contract
|
|
7
|
-
* ceiling, not a provider limit — if a provider turns out to cap a lease
|
|
8
|
-
* sooner, the real number belongs here and selection will start refusing jobs
|
|
9
|
-
* that ask for longer, which is the correct outcome.
|
|
10
|
-
*/
|
|
11
|
-
const FORGE_JOB_CONTRACT_CEILING_SECONDS = 7 * 24 * 60 * 60;
|
|
12
|
-
/**
|
|
13
|
-
* Cloudflare Containers `standard-4` — what `forge-ci-worker` runs on today
|
|
14
|
-
* (`wrangler.jsonc`, `instance_type: "standard-4"`): 4 vCPU, 12 GiB memory,
|
|
15
|
-
* 20 GB disk.
|
|
16
|
-
*
|
|
17
|
-
* Cloudflare bills memory and disk on PROVISIONED resources and CPU on ACTIVE
|
|
18
|
-
* usage only (a November 2025 pricing change), so the two rates are split.
|
|
19
|
-
* A CI job is CPU-bound almost by definition, so its real cost sits near
|
|
20
|
-
* `usdPerSecond + usdPerSecondCpuActive`; an idle container costs the floor.
|
|
21
|
-
*/
|
|
22
|
-
export const cfContainerStandard4 = {
|
|
23
|
-
kind: 'infra/compute-source',
|
|
24
|
-
id: 'cf-container-standard-4',
|
|
25
|
-
name: 'Cloudflare Containers standard-4',
|
|
26
|
-
description: '4 vCPU / 12 GiB / 20 GB Cloudflare container, the current Forge CI executor',
|
|
27
|
-
provides: { os: ['linux'], arch: ['x64'], labels: [] },
|
|
28
|
-
ephemeral: true,
|
|
29
|
-
cost: {
|
|
30
|
-
// Provisioned floor: memory + disk bill for the whole lease.
|
|
31
|
-
// 12 GiB × $0.0000025/GiB-s + 20 GB × $0.00000007/GB-s
|
|
32
|
-
usdPerSecond: 12 * 0.0000025 + 20 * 0.00000007,
|
|
33
|
-
// Charged on top, only while the vCPUs are busy.
|
|
34
|
-
// 4 vCPU × $0.000020/vCPU-s
|
|
35
|
-
usdPerSecondCpuActive: 4 * 0.00002,
|
|
36
|
-
source: 'published',
|
|
37
|
-
confidence: 'high',
|
|
38
|
-
effectiveAt: QUOTED_AT,
|
|
39
|
-
note: 'developers.cloudflare.com/containers/pricing, read 2026-09-08. Excludes the $5/mo Workers Paid plan and the included monthly allotment (25 GiB-hours memory, 375 vCPU-minutes, 200 GB-hours disk), which are account-level and not attributable to one lease.'
|
|
40
|
-
},
|
|
41
|
-
ownerScope: 'vibes',
|
|
42
|
-
// Conservative: a Durable Object container sleeps on inactivity rather than
|
|
43
|
-
// holding reserved warm capacity we can hand to the next job.
|
|
44
|
-
warmPool: false,
|
|
45
|
-
maxLeaseSeconds: FORGE_JOB_CONTRACT_CEILING_SECONDS,
|
|
46
|
-
// Left false pending someone verifying an in-flight container can actually
|
|
47
|
-
// be torn down mid-job. False under-sells the source; a wrong true would
|
|
48
|
-
// have the allocator promise a cancellation it cannot perform.
|
|
49
|
-
supportsCancellation: false
|
|
50
|
-
};
|
|
51
|
-
/**
|
|
52
|
-
* DigitalOcean droplet `s-2vcpu-4gb`: 2 vCPU, 4 GiB memory, 80 GB disk.
|
|
53
|
-
*
|
|
54
|
-
* Billed per second with a floor of 60 seconds or $0.01, whichever is higher.
|
|
55
|
-
* At this size 60 seconds is $0.000595, so $0.01 is always the binding floor —
|
|
56
|
-
* which means a 10-second lease and a 16-minute lease cost the same.
|
|
57
|
-
*/
|
|
58
|
-
export const doDropletS2vcpu4gb = {
|
|
59
|
-
kind: 'infra/compute-source',
|
|
60
|
-
id: 'do-droplet-s-2vcpu-4gb',
|
|
61
|
-
name: 'DigitalOcean droplet s-2vcpu-4gb',
|
|
62
|
-
description: '2 vCPU / 4 GiB / 80 GB DigitalOcean droplet',
|
|
63
|
-
// No arm64: the account's own /v2/sizes listing returns no arm slugs at all,
|
|
64
|
-
// so claiming arm64 here would be a capability we cannot provision.
|
|
65
|
-
provides: { os: ['linux'], arch: ['x64'], labels: [] },
|
|
66
|
-
// A fleet host outlives the job it was leased for, which is precisely why
|
|
67
|
-
// it must not be handed unreviewed code.
|
|
68
|
-
ephemeral: false,
|
|
69
|
-
cost: {
|
|
70
|
-
// DigitalOcean's own published hourly rate for this slug, per second.
|
|
71
|
-
// Read live from GET /v2/sizes rather than divided out of the monthly price.
|
|
72
|
-
usdPerSecond: 0.03571 / 3600,
|
|
73
|
-
// "billed per second with a minimum charge of 60 seconds or $0.01,
|
|
74
|
-
// whichever is higher" — a floor on the lease, never added to it.
|
|
75
|
-
minimumUsd: 0.01,
|
|
76
|
-
source: 'published',
|
|
77
|
-
confidence: 'high',
|
|
78
|
-
effectiveAt: QUOTED_AT,
|
|
79
|
-
note: 'DigitalOcean GET /v2/sizes price_hourly=0.03571 for s-2vcpu-4gb, read 2026-09-08; minimum charge from docs.digitalocean.com/products/droplets/details/pricing. Bundled-plan usage is capped at 672h/month, which caps a long-lived host but not a single lease.'
|
|
80
|
-
},
|
|
81
|
-
ownerScope: 'vibes',
|
|
82
|
-
// A persistent host is reusable capacity by construction.
|
|
83
|
-
warmPool: true,
|
|
84
|
-
maxLeaseSeconds: FORGE_JOB_CONTRACT_CEILING_SECONDS,
|
|
85
|
-
// `vibes fleet destroy` exists and does this.
|
|
86
|
-
supportsCancellation: true
|
|
87
|
-
};
|
|
88
|
-
/** Every compute source we own, cheapest-first ordering left to the selector. */
|
|
89
|
-
export const vibesComputeSources = [
|
|
90
|
-
cfContainerStandard4,
|
|
91
|
-
doDropletS2vcpu4gb
|
|
92
|
-
];
|
|
93
|
-
//# sourceMappingURL=compute-sources.descriptors.js.map
|
|
@@ -1 +0,0 @@
|
|
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