@vibesdotdev/infra-core 0.0.2 → 1.0.0-rc.5
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/LICENSE +18 -0
- package/README.md +27 -1
- package/dist/bootstrap/seed.descriptor.d.ts +1 -1
- package/dist/bootstrap/seed.descriptor.d.ts.map +1 -1
- package/dist/bootstrap/seed.descriptor.js +1 -1
- package/dist/bootstrap/seed.descriptor.js.map +1 -1
- package/dist/bootstrap/seed.impl-shape.d.ts +1 -1
- package/dist/bootstrap/seed.impl-shape.d.ts.map +1 -1
- package/dist/bootstrap/seed.kind.d.ts +1 -3
- package/dist/bootstrap/seed.kind.d.ts.map +1 -1
- package/dist/bootstrap/seed.kind.js +17 -4
- package/dist/bootstrap/seed.kind.js.map +1 -1
- package/dist/bootstrap/seed.runner.d.ts +9 -2
- package/dist/bootstrap/seed.runner.d.ts.map +1 -1
- package/dist/bootstrap/seed.runner.js +37 -18
- package/dist/bootstrap/seed.runner.js.map +1 -1
- package/dist/capped-id.d.ts +19 -0
- package/dist/capped-id.d.ts.map +1 -0
- package/dist/capped-id.js +64 -0
- package/dist/capped-id.js.map +1 -0
- package/dist/cli/generate/artifact/artifact.cli-command.descriptor.d.ts +23 -0
- package/dist/cli/generate/artifact/artifact.cli-command.descriptor.d.ts.map +1 -0
- package/dist/cli/generate/artifact/artifact.cli-command.descriptor.js +33 -0
- package/dist/cli/generate/artifact/artifact.cli-command.descriptor.js.map +1 -0
- package/dist/cli/generate/artifact/artifact.cli-command.impl.d.ts +24 -0
- package/dist/cli/generate/artifact/artifact.cli-command.impl.d.ts.map +1 -0
- package/dist/cli/generate/artifact/artifact.cli-command.impl.js +73 -0
- package/dist/cli/generate/artifact/artifact.cli-command.impl.js.map +1 -0
- package/dist/cli/generate/context.d.ts +17 -0
- package/dist/cli/generate/context.d.ts.map +1 -0
- package/dist/cli/generate/context.js +24 -0
- package/dist/cli/generate/context.js.map +1 -0
- package/dist/cli/generate/generate/generate.cli-command.descriptor.d.ts +30 -0
- package/dist/cli/generate/generate/generate.cli-command.descriptor.d.ts.map +1 -0
- package/dist/cli/generate/generate/generate.cli-command.descriptor.js +25 -0
- package/dist/cli/generate/generate/generate.cli-command.descriptor.js.map +1 -0
- package/dist/cli/generate/generate/generate.cli-command.impl.d.ts +25 -0
- package/dist/cli/generate/generate/generate.cli-command.impl.d.ts.map +1 -0
- package/dist/cli/generate/generate/generate.cli-command.impl.js +64 -0
- package/dist/cli/generate/generate/generate.cli-command.impl.js.map +1 -0
- package/dist/cli/generate/generate-core.d.ts +51 -0
- package/dist/cli/generate/generate-core.d.ts.map +1 -0
- package/dist/cli/generate/generate-core.js +172 -0
- package/dist/cli/generate/generate-core.js.map +1 -0
- package/dist/cli/generate/index.d.ts +5 -0
- package/dist/cli/generate/index.d.ts.map +1 -0
- package/dist/cli/generate/index.js +5 -0
- package/dist/cli/generate/index.js.map +1 -0
- package/dist/credentials/resolve.d.ts +82 -22
- package/dist/credentials/resolve.d.ts.map +1 -1
- package/dist/credentials/resolve.js +251 -77
- package/dist/credentials/resolve.js.map +1 -1
- package/dist/deployment-environment.d.ts +30 -0
- package/dist/deployment-environment.d.ts.map +1 -0
- package/dist/deployment-environment.js +53 -0
- package/dist/deployment-environment.js.map +1 -0
- package/dist/deployment.d.ts +8 -4
- package/dist/deployment.d.ts.map +1 -1
- package/dist/deployment.js +30 -0
- package/dist/deployment.js.map +1 -1
- package/dist/doks/cloud/base.d.ts +49 -0
- package/dist/doks/cloud/base.d.ts.map +1 -0
- package/dist/doks/cloud/base.js +138 -0
- package/dist/doks/cloud/base.js.map +1 -0
- package/dist/doks/cloud/factory.d.ts +18 -0
- package/dist/doks/cloud/factory.d.ts.map +1 -0
- package/dist/doks/cloud/factory.js +22 -0
- package/dist/doks/cloud/factory.js.map +1 -0
- package/dist/doks/cloud/index.d.ts +5 -0
- package/dist/doks/cloud/index.d.ts.map +1 -0
- package/dist/doks/cloud/index.js +4 -0
- package/dist/doks/cloud/index.js.map +1 -0
- package/dist/doks/types.d.ts +95 -0
- package/dist/doks/types.d.ts.map +1 -0
- package/dist/doks/types.js +14 -0
- package/dist/doks/types.js.map +1 -0
- package/dist/generate/index.d.ts +29 -0
- package/dist/generate/index.d.ts.map +1 -0
- package/dist/generate/index.js +28 -0
- package/dist/generate/index.js.map +1 -0
- package/dist/generate/infra-generate.plugin.d.ts +3 -0
- package/dist/generate/infra-generate.plugin.d.ts.map +1 -0
- package/dist/generate/infra-generate.plugin.js +23 -0
- package/dist/generate/infra-generate.plugin.js.map +1 -0
- package/dist/generate/plugin.d.ts +2 -0
- package/dist/generate/plugin.d.ts.map +1 -0
- package/dist/generate/plugin.js +2 -0
- package/dist/generate/plugin.js.map +1 -0
- package/dist/heartbeat/cron-heartbeat.d.ts +97 -0
- package/dist/heartbeat/cron-heartbeat.d.ts.map +1 -0
- package/dist/heartbeat/cron-heartbeat.js +200 -0
- package/dist/heartbeat/cron-heartbeat.js.map +1 -0
- package/dist/index.d.ts +35 -21
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +28 -14
- package/dist/index.js.map +1 -1
- package/dist/infra.plugin.d.ts +1 -1
- package/dist/infra.plugin.d.ts.map +1 -1
- package/dist/infra.plugin.js +62 -12
- package/dist/infra.plugin.js.map +1 -1
- package/dist/kinds/alerts.kind.d.ts +64 -25
- package/dist/kinds/alerts.kind.d.ts.map +1 -1
- package/dist/kinds/alerts.kind.js +43 -16
- package/dist/kinds/alerts.kind.js.map +1 -1
- package/dist/kinds/artifact.kind.d.ts +58 -10
- package/dist/kinds/artifact.kind.d.ts.map +1 -1
- package/dist/kinds/artifact.kind.js +26 -9
- package/dist/kinds/artifact.kind.js.map +1 -1
- package/dist/kinds/billing.kind.d.ts +88 -0
- package/dist/kinds/billing.kind.d.ts.map +1 -0
- package/dist/kinds/billing.kind.js +48 -0
- package/dist/kinds/billing.kind.js.map +1 -0
- package/dist/kinds/build-job.kind.d.ts +381 -0
- package/dist/kinds/build-job.kind.d.ts.map +1 -0
- package/dist/kinds/build-job.kind.js +216 -0
- package/dist/kinds/build-job.kind.js.map +1 -0
- package/dist/kinds/cache.kind.d.ts +39 -92
- package/dist/kinds/cache.kind.d.ts.map +1 -1
- package/dist/kinds/cache.kind.js +26 -51
- package/dist/kinds/cache.kind.js.map +1 -1
- package/dist/kinds/cluster.kind.d.ts +154 -0
- package/dist/kinds/cluster.kind.d.ts.map +1 -0
- package/dist/kinds/cluster.kind.js +99 -0
- package/dist/kinds/cluster.kind.js.map +1 -0
- package/dist/kinds/compute-source.kind.d.ts +138 -0
- package/dist/kinds/compute-source.kind.d.ts.map +1 -0
- package/dist/kinds/compute-source.kind.js +145 -0
- package/dist/kinds/compute-source.kind.js.map +1 -0
- package/dist/kinds/compute-sources.descriptors.d.ts +45 -0
- package/dist/kinds/compute-sources.descriptors.d.ts.map +1 -0
- package/dist/kinds/compute-sources.descriptors.js +93 -0
- package/dist/kinds/compute-sources.descriptors.js.map +1 -0
- package/dist/kinds/container-registry.kind.d.ts +62 -0
- package/dist/kinds/container-registry.kind.d.ts.map +1 -0
- package/dist/kinds/container-registry.kind.js +47 -0
- package/dist/kinds/container-registry.kind.js.map +1 -0
- package/dist/kinds/database-migrator.kind.d.ts +6 -0
- package/dist/kinds/database-migrator.kind.d.ts.map +1 -0
- package/dist/kinds/database-migrator.kind.js +28 -0
- package/dist/kinds/database-migrator.kind.js.map +1 -0
- package/dist/kinds/database.kind.d.ts +114 -93
- package/dist/kinds/database.kind.d.ts.map +1 -1
- package/dist/kinds/database.kind.js +93 -54
- package/dist/kinds/database.kind.js.map +1 -1
- package/dist/kinds/deployment-provider.kind.d.ts +5 -0
- package/dist/kinds/deployment-provider.kind.d.ts.map +1 -0
- package/dist/kinds/deployment-provider.kind.js +11 -0
- package/dist/kinds/deployment-provider.kind.js.map +1 -0
- package/dist/kinds/discovery.d.ts +5 -12
- package/dist/kinds/discovery.d.ts.map +1 -1
- package/dist/kinds/discovery.js +5 -17
- package/dist/kinds/discovery.js.map +1 -1
- package/dist/kinds/dns.kind.d.ts +162 -0
- package/dist/kinds/dns.kind.d.ts.map +1 -0
- package/dist/kinds/dns.kind.js +54 -0
- package/dist/kinds/dns.kind.js.map +1 -0
- package/dist/kinds/drift.kind.d.ts +115 -0
- package/dist/kinds/drift.kind.d.ts.map +1 -0
- package/dist/kinds/drift.kind.js +60 -0
- package/dist/kinds/drift.kind.js.map +1 -0
- package/dist/kinds/edge-tls.kind.d.ts +194 -0
- package/dist/kinds/edge-tls.kind.d.ts.map +1 -0
- package/dist/kinds/edge-tls.kind.js +58 -0
- package/dist/kinds/edge-tls.kind.js.map +1 -0
- package/dist/kinds/firewall.kind.d.ts +92 -0
- package/dist/kinds/firewall.kind.d.ts.map +1 -0
- package/dist/kinds/firewall.kind.js +59 -0
- package/dist/kinds/firewall.kind.js.map +1 -0
- package/dist/kinds/git-hosting.kind.d.ts +36 -38
- package/dist/kinds/git-hosting.kind.d.ts.map +1 -1
- package/dist/kinds/git-hosting.kind.js +21 -32
- package/dist/kinds/git-hosting.kind.js.map +1 -1
- package/dist/kinds/index.d.ts +40 -15
- package/dist/kinds/index.d.ts.map +1 -1
- package/dist/kinds/index.js +39 -14
- package/dist/kinds/index.js.map +1 -1
- package/dist/kinds/inventory.kind.d.ts +327 -0
- package/dist/kinds/inventory.kind.d.ts.map +1 -0
- package/dist/kinds/inventory.kind.js +188 -0
- package/dist/kinds/inventory.kind.js.map +1 -0
- package/dist/kinds/load-balancer.kind.d.ts +135 -0
- package/dist/kinds/load-balancer.kind.d.ts.map +1 -0
- package/dist/kinds/load-balancer.kind.js +71 -0
- package/dist/kinds/load-balancer.kind.js.map +1 -0
- package/dist/kinds/logs.kind.d.ts +74 -3
- package/dist/kinds/logs.kind.d.ts.map +1 -1
- package/dist/kinds/logs.kind.js +26 -17
- package/dist/kinds/logs.kind.js.map +1 -1
- package/dist/kinds/nfs.kind.d.ts +67 -0
- package/dist/kinds/nfs.kind.d.ts.map +1 -0
- package/dist/kinds/nfs.kind.js +45 -0
- package/dist/kinds/nfs.kind.js.map +1 -0
- package/dist/kinds/node-pool.kind.d.ts +134 -0
- package/dist/kinds/node-pool.kind.d.ts.map +1 -0
- package/dist/kinds/node-pool.kind.js +88 -0
- package/dist/kinds/node-pool.kind.js.map +1 -0
- package/dist/kinds/object-storage.kind.d.ts +50 -24
- package/dist/kinds/object-storage.kind.d.ts.map +1 -1
- package/dist/kinds/object-storage.kind.js +40 -23
- package/dist/kinds/object-storage.kind.js.map +1 -1
- package/dist/kinds/observability.kind.d.ts +104 -6
- package/dist/kinds/observability.kind.d.ts.map +1 -1
- package/dist/kinds/observability.kind.js +67 -9
- package/dist/kinds/observability.kind.js.map +1 -1
- package/dist/kinds/package-registry.kind.d.ts +139 -33
- package/dist/kinds/package-registry.kind.d.ts.map +1 -1
- package/dist/kinds/package-registry.kind.js +55 -25
- package/dist/kinds/package-registry.kind.js.map +1 -1
- package/dist/kinds/queue.kind.d.ts +67 -63
- package/dist/kinds/queue.kind.d.ts.map +1 -1
- package/dist/kinds/queue.kind.js +55 -33
- package/dist/kinds/queue.kind.js.map +1 -1
- package/dist/kinds/read-descriptor.d.ts +15 -0
- package/dist/kinds/read-descriptor.d.ts.map +1 -0
- package/dist/kinds/read-descriptor.js +11 -0
- package/dist/kinds/read-descriptor.js.map +1 -0
- package/dist/kinds/rum.kind.d.ts +36 -6
- package/dist/kinds/rum.kind.d.ts.map +1 -1
- package/dist/kinds/rum.kind.js +6 -7
- package/dist/kinds/rum.kind.js.map +1 -1
- package/dist/kinds/sandbox.kind.d.ts +136 -36
- package/dist/kinds/sandbox.kind.d.ts.map +1 -1
- package/dist/kinds/sandbox.kind.js +80 -34
- package/dist/kinds/sandbox.kind.js.map +1 -1
- package/dist/kinds/select-compute-source.d.ts +72 -0
- package/dist/kinds/select-compute-source.d.ts.map +1 -0
- package/dist/kinds/select-compute-source.js +170 -0
- package/dist/kinds/select-compute-source.js.map +1 -0
- package/dist/kinds/service-release.kind.d.ts +771 -0
- package/dist/kinds/service-release.kind.d.ts.map +1 -0
- package/dist/kinds/service-release.kind.js +676 -0
- package/dist/kinds/service-release.kind.js.map +1 -0
- package/dist/kinds/spend-guard.kind.d.ts +40 -0
- package/dist/kinds/spend-guard.kind.d.ts.map +1 -0
- package/dist/kinds/spend-guard.kind.js +133 -0
- package/dist/kinds/spend-guard.kind.js.map +1 -0
- package/dist/kinds/utilization.kind.d.ts +88 -0
- package/dist/kinds/utilization.kind.d.ts.map +1 -0
- package/dist/kinds/utilization.kind.js +62 -0
- package/dist/kinds/utilization.kind.js.map +1 -0
- package/dist/kinds/volume.kind.d.ts +54 -0
- package/dist/kinds/volume.kind.d.ts.map +1 -0
- package/dist/kinds/volume.kind.js +39 -0
- package/dist/kinds/volume.kind.js.map +1 -0
- package/dist/kinds/vpc.kind.d.ts +61 -0
- package/dist/kinds/vpc.kind.d.ts.map +1 -0
- package/dist/kinds/vpc.kind.js +51 -0
- package/dist/kinds/vpc.kind.js.map +1 -0
- package/dist/kinds/web-app.kind.d.ts +115 -45
- package/dist/kinds/web-app.kind.d.ts.map +1 -1
- package/dist/kinds/web-app.kind.js +69 -42
- package/dist/kinds/web-app.kind.js.map +1 -1
- package/dist/kinds/worker.kind.d.ts +293 -188
- package/dist/kinds/worker.kind.d.ts.map +1 -1
- package/dist/kinds/worker.kind.js +45 -123
- package/dist/kinds/worker.kind.js.map +1 -1
- package/dist/schemas/database-migration.d.ts +173 -0
- package/dist/schemas/database-migration.d.ts.map +1 -0
- package/dist/schemas/database-migration.js +88 -0
- package/dist/schemas/database-migration.js.map +1 -0
- package/dist/schemas/deployment-environment.d.ts +11 -0
- package/dist/schemas/deployment-environment.d.ts.map +1 -0
- package/dist/schemas/deployment-environment.js +9 -0
- package/dist/schemas/deployment-environment.js.map +1 -0
- package/dist/schemas/deployment-provider.d.ts +336 -0
- package/dist/schemas/deployment-provider.d.ts.map +1 -0
- package/dist/schemas/deployment-provider.js +198 -0
- package/dist/schemas/deployment-provider.js.map +1 -0
- package/dist/schemas/log-stream.d.ts +27 -0
- package/dist/schemas/log-stream.d.ts.map +1 -0
- package/dist/schemas/log-stream.js +31 -0
- package/dist/schemas/log-stream.js.map +1 -0
- package/dist/schemas/spend-guard.d.ts +155 -0
- package/dist/schemas/spend-guard.d.ts.map +1 -0
- package/dist/schemas/spend-guard.js +61 -0
- package/dist/schemas/spend-guard.js.map +1 -0
- package/dist/schemas.d.ts +190 -20
- package/dist/schemas.d.ts.map +1 -1
- package/dist/schemas.js +137 -31
- package/dist/schemas.js.map +1 -1
- package/dist/service.d.ts +87 -0
- package/dist/service.d.ts.map +1 -0
- package/dist/service.js +199 -0
- package/dist/service.js.map +1 -0
- package/dist/settle-work.d.ts +20 -0
- package/dist/settle-work.d.ts.map +1 -0
- package/dist/settle-work.js +22 -0
- package/dist/settle-work.js.map +1 -0
- package/dist/web-app-projection.d.ts +132 -0
- package/dist/web-app-projection.d.ts.map +1 -0
- package/dist/web-app-projection.js +93 -0
- package/dist/web-app-projection.js.map +1 -0
- package/package.json +87 -36
- package/src/bootstrap/index.ts +0 -15
- package/src/bootstrap/seed.descriptor.ts +0 -24
- package/src/bootstrap/seed.impl-shape.ts +0 -5
- package/src/bootstrap/seed.kind.ts +0 -26
- package/src/bootstrap/seed.runner.ts +0 -87
- package/src/credentials/resolve.ts +0 -205
- package/src/deployment.ts +0 -57
- package/src/index.ts +0 -149
- package/src/infra.plugin.ts +0 -54
- package/src/kinds/alerts.kind.ts +0 -164
- package/src/kinds/artifact.kind.ts +0 -96
- package/src/kinds/cache.kind.ts +0 -104
- package/src/kinds/database.kind.ts +0 -120
- package/src/kinds/discovery.ts +0 -26
- package/src/kinds/git-hosting.kind.ts +0 -100
- package/src/kinds/index.ts +0 -139
- package/src/kinds/logs.kind.ts +0 -104
- package/src/kinds/object-storage.kind.ts +0 -101
- package/src/kinds/observability.kind.ts +0 -178
- package/src/kinds/package-registry.kind.ts +0 -95
- package/src/kinds/queue.kind.ts +0 -102
- package/src/kinds/rum.kind.ts +0 -135
- package/src/kinds/sandbox.kind.ts +0 -115
- package/src/kinds/web-app.kind.ts +0 -103
- package/src/kinds/worker.kind.ts +0 -203
- package/src/schemas.ts +0 -127
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
/** Provider-neutral read-only account economics. */
|
|
2
|
+
import * as z from 'zod/v4';
|
|
3
|
+
import { createRuntimeKind } from '@vibesdotdev/kernel/factory/kind';
|
|
4
|
+
import { RuntimeDescriptorSchema } from '@vibesdotdev/kernel/schemas/descriptor';
|
|
5
|
+
import { readKindDescriptor } from "./read-descriptor.js";
|
|
6
|
+
import { INFRA_DISCOVERY_PATTERNS } from "./discovery.js";
|
|
7
|
+
export const BillingMoneySchema = z.object({
|
|
8
|
+
currency: z.string().regex(/^[A-Z]{3}$/, 'currency must be an ISO 4217-style code'),
|
|
9
|
+
amount: z.string().regex(/^-?\d+(?:\.\d+)?$/, 'amount must be a decimal string')
|
|
10
|
+
});
|
|
11
|
+
export const BillingSummarySchema = z.object({
|
|
12
|
+
provider: z.string().min(1),
|
|
13
|
+
collectedAt: z.iso.datetime({ offset: true }),
|
|
14
|
+
accountBalance: BillingMoneySchema.optional(),
|
|
15
|
+
monthToDateUsage: BillingMoneySchema.optional(),
|
|
16
|
+
monthToDateBalance: BillingMoneySchema.optional(),
|
|
17
|
+
grossProductCharges: BillingMoneySchema.optional(),
|
|
18
|
+
invoiceCreditsAndAdjustments: BillingMoneySchema.optional(),
|
|
19
|
+
sponsorshipCredits: z.object({
|
|
20
|
+
status: z.enum(['available', 'unknown', 'unsupported']),
|
|
21
|
+
remaining: BillingMoneySchema.optional(),
|
|
22
|
+
expiresAt: z.iso.datetime({ offset: true }).optional(),
|
|
23
|
+
reason: z.string().optional()
|
|
24
|
+
}),
|
|
25
|
+
errors: z.array(z.object({ source: z.string(), message: z.string() }))
|
|
26
|
+
});
|
|
27
|
+
export const BillingDescriptorSchema = RuntimeDescriptorSchema.extend({
|
|
28
|
+
kind: z.literal('infra/billing'),
|
|
29
|
+
provider: z.string().min(1).optional()
|
|
30
|
+
});
|
|
31
|
+
class DefaultBillingImplementation {
|
|
32
|
+
descriptor;
|
|
33
|
+
context;
|
|
34
|
+
/** The descriptor as this kind's schema reads it. */
|
|
35
|
+
config;
|
|
36
|
+
constructor(descriptor, context) {
|
|
37
|
+
this.descriptor = descriptor;
|
|
38
|
+
this.context = context;
|
|
39
|
+
this.config = readKindDescriptor(BillingDescriptorSchema, descriptor);
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
export const billingKind = createRuntimeKind({
|
|
43
|
+
id: 'infra/billing',
|
|
44
|
+
descriptorSchema: BillingDescriptorSchema,
|
|
45
|
+
defaultImplementation: DefaultBillingImplementation,
|
|
46
|
+
discoveryPatterns: INFRA_DISCOVERY_PATTERNS
|
|
47
|
+
});
|
|
48
|
+
//# sourceMappingURL=billing.kind.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"billing.kind.js","sourceRoot":"","sources":["../../src/kinds/billing.kind.ts"],"names":[],"mappings":"AAAA,oDAAoD;AACpD,OAAO,KAAK,CAAC,MAAM,QAAQ,CAAC;AAC5B,OAAO,EAAE,iBAAiB,EAAE,MAAM,kCAAkC,CAAC;AACrE,OAAO,EAAE,uBAAuB,EAAE,MAAM,wCAAwC,CAAC;AAGjF,OAAO,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAC1D,OAAO,EAAE,wBAAwB,EAAE,MAAM,gBAAgB,CAAC;AAC1D,MAAM,CAAC,MAAM,kBAAkB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC1C,QAAQ,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,KAAK,CAAC,YAAY,EAAE,yCAAyC,CAAC;IACnF,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,KAAK,CAAC,mBAAmB,EAAE,iCAAiC,CAAC;CAChF,CAAC,CAAC;AACH,MAAM,CAAC,MAAM,oBAAoB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC5C,QAAQ,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC;IAC3B,WAAW,EAAE,CAAC,CAAC,GAAG,CAAC,QAAQ,CAAC,EAAE,MAAM,EAAE,IAAI,EAAE,CAAC;IAC7C,cAAc,EAAE,kBAAkB,CAAC,QAAQ,EAAE;IAC7C,gBAAgB,EAAE,kBAAkB,CAAC,QAAQ,EAAE;IAC/C,kBAAkB,EAAE,kBAAkB,CAAC,QAAQ,EAAE;IACjD,mBAAmB,EAAE,kBAAkB,CAAC,QAAQ,EAAE;IAClD,4BAA4B,EAAE,kBAAkB,CAAC,QAAQ,EAAE;IAC3D,kBAAkB,EAAE,CAAC,CAAC,MAAM,CAAC;QAC5B,MAAM,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC,WAAW,EAAE,SAAS,EAAE,aAAa,CAAC,CAAC;QACvD,SAAS,EAAE,kBAAkB,CAAC,QAAQ,EAAE;QACxC,SAAS,EAAE,CAAC,CAAC,GAAG,CAAC,QAAQ,CAAC,EAAE,MAAM,EAAE,IAAI,EAAE,CAAC,CAAC,QAAQ,EAAE;QACtD,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;KAC7B,CAAC;IACF,MAAM,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,EAAE,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC;CACtE,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,uBAAuB,GAAG,uBAAuB,CAAC,MAAM,CAAC;IACrE,IAAI,EAAE,CAAC,CAAC,OAAO,CAAC,eAAe,CAAC;IAChC,QAAQ,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,QAAQ,EAAE;CACtC,CAAC,CAAC;AAKH,MAAM,4BAA4B;IAIhB;IACA;IAJjB,qDAAqD;IAC5C,MAAM,CAAoB;IACnC,YACiB,UAA6B,EAC7B,OAAoB;QADpB,eAAU,GAAV,UAAU,CAAmB;QAC7B,YAAO,GAAP,OAAO,CAAa;QAEpC,IAAI,CAAC,MAAM,GAAG,kBAAkB,CAAC,uBAAuB,EAAE,UAAU,CAAC,CAAC;IACvE,CAAC;CACD;AACD,MAAM,CAAC,MAAM,WAAW,GAAG,iBAAiB,CAAkD;IAC7F,EAAE,EAAE,eAAe;IACnB,gBAAgB,EAAE,uBAAuB;IACzC,qBAAqB,EAAE,4BAA4B;IACnD,iBAAiB,EAAE,wBAAwB;CAC3C,CAAC,CAAC"}
|
|
@@ -0,0 +1,381 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Kind: infra/build-job
|
|
3
|
+
*
|
|
4
|
+
* Provider-neutral descriptor for reproducible release builds. Adapter
|
|
5
|
+
* packages map this shape onto DOKS Kubernetes Jobs, local Docker runs,
|
|
6
|
+
* Windows VM runners, or another execution substrate.
|
|
7
|
+
*/
|
|
8
|
+
import * as z from 'zod/v4';
|
|
9
|
+
import type { RuntimeDescriptor } from '@vibesdotdev/kernel/schemas/descriptor';
|
|
10
|
+
import type { KindContext } from '@vibesdotdev/kernel/schemas/kind';
|
|
11
|
+
export declare const BuildTargetOsSchema: z.ZodEnum<{
|
|
12
|
+
linux: "linux";
|
|
13
|
+
macos: "macos";
|
|
14
|
+
windows: "windows";
|
|
15
|
+
}>;
|
|
16
|
+
export declare const BuildTargetArchSchema: z.ZodEnum<{
|
|
17
|
+
x64: "x64";
|
|
18
|
+
arm64: "arm64";
|
|
19
|
+
}>;
|
|
20
|
+
export declare const BuildJobTargetSchema: z.ZodObject<{
|
|
21
|
+
os: z.ZodEnum<{
|
|
22
|
+
linux: "linux";
|
|
23
|
+
macos: "macos";
|
|
24
|
+
windows: "windows";
|
|
25
|
+
}>;
|
|
26
|
+
arch: z.ZodEnum<{
|
|
27
|
+
x64: "x64";
|
|
28
|
+
arm64: "arm64";
|
|
29
|
+
}>;
|
|
30
|
+
libc: z.ZodOptional<z.ZodEnum<{
|
|
31
|
+
glibc: "glibc";
|
|
32
|
+
musl: "musl";
|
|
33
|
+
msvc: "msvc";
|
|
34
|
+
}>>;
|
|
35
|
+
format: z.ZodOptional<z.ZodString>;
|
|
36
|
+
}, z.core.$strip>;
|
|
37
|
+
export type BuildJobTarget = z.infer<typeof BuildJobTargetSchema>;
|
|
38
|
+
/**
|
|
39
|
+
* A build never carries a repository password/token. It carries only enough
|
|
40
|
+
* authority metadata for the execution adapter to ask the platform broker for
|
|
41
|
+
* one operation-scoped read credential at checkout time.
|
|
42
|
+
*/
|
|
43
|
+
export declare const BuildJobGitAuthenticationSchema: z.ZodObject<{
|
|
44
|
+
mode: z.ZodLiteral<"brokered">;
|
|
45
|
+
provider: z.ZodLiteral<"vibes-forge">;
|
|
46
|
+
repositoryId: z.ZodString;
|
|
47
|
+
brokerOrigin: z.ZodString;
|
|
48
|
+
serviceCredential: z.ZodObject<{
|
|
49
|
+
source: z.ZodLiteral<"secret">;
|
|
50
|
+
key: z.ZodString;
|
|
51
|
+
}, z.core.$strip>;
|
|
52
|
+
}, z.core.$strict>;
|
|
53
|
+
export type BuildJobGitAuthentication = z.infer<typeof BuildJobGitAuthenticationSchema>;
|
|
54
|
+
export declare const BuildJobSourceSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
55
|
+
kind: z.ZodLiteral<"git">;
|
|
56
|
+
repository: z.ZodString;
|
|
57
|
+
ref: z.ZodOptional<z.ZodString>;
|
|
58
|
+
depth: z.ZodDefault<z.ZodNumber>;
|
|
59
|
+
checkoutDir: z.ZodDefault<z.ZodString>;
|
|
60
|
+
authentication: z.ZodOptional<z.ZodObject<{
|
|
61
|
+
mode: z.ZodLiteral<"brokered">;
|
|
62
|
+
provider: z.ZodLiteral<"vibes-forge">;
|
|
63
|
+
repositoryId: z.ZodString;
|
|
64
|
+
brokerOrigin: z.ZodString;
|
|
65
|
+
serviceCredential: z.ZodObject<{
|
|
66
|
+
source: z.ZodLiteral<"secret">;
|
|
67
|
+
key: z.ZodString;
|
|
68
|
+
}, z.core.$strip>;
|
|
69
|
+
}, z.core.$strict>>;
|
|
70
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
71
|
+
kind: z.ZodLiteral<"workspace">;
|
|
72
|
+
path: z.ZodDefault<z.ZodString>;
|
|
73
|
+
}, z.core.$strip>], "kind">;
|
|
74
|
+
export type BuildJobSource = z.infer<typeof BuildJobSourceSchema>;
|
|
75
|
+
export declare const BuildJobStepSchema: z.ZodObject<{
|
|
76
|
+
name: z.ZodString;
|
|
77
|
+
run: z.ZodString;
|
|
78
|
+
cwd: z.ZodOptional<z.ZodString>;
|
|
79
|
+
shell: z.ZodOptional<z.ZodString>;
|
|
80
|
+
}, z.core.$strip>;
|
|
81
|
+
export type BuildJobStep = z.infer<typeof BuildJobStepSchema>;
|
|
82
|
+
export declare const BuildJobArtifactSchema: z.ZodObject<{
|
|
83
|
+
path: z.ZodString;
|
|
84
|
+
name: z.ZodOptional<z.ZodString>;
|
|
85
|
+
contentType: z.ZodOptional<z.ZodString>;
|
|
86
|
+
required: z.ZodDefault<z.ZodBoolean>;
|
|
87
|
+
}, z.core.$strip>;
|
|
88
|
+
export type BuildJobArtifact = z.infer<typeof BuildJobArtifactSchema>;
|
|
89
|
+
export declare const BuildJobToolRequirementSchema: z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
|
|
90
|
+
id: z.ZodString;
|
|
91
|
+
required: z.ZodDefault<z.ZodBoolean>;
|
|
92
|
+
labels: z.ZodDefault<z.ZodArray<z.ZodString>>;
|
|
93
|
+
}, z.core.$strip>]>;
|
|
94
|
+
export type BuildJobToolRequirement = z.infer<typeof BuildJobToolRequirementSchema>;
|
|
95
|
+
export declare const BuildJobRequirementsSchema: z.ZodObject<{
|
|
96
|
+
hostPoolId: z.ZodOptional<z.ZodString>;
|
|
97
|
+
runnerLabel: z.ZodOptional<z.ZodString>;
|
|
98
|
+
labels: z.ZodDefault<z.ZodArray<z.ZodString>>;
|
|
99
|
+
tools: z.ZodDefault<z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
|
|
100
|
+
id: z.ZodString;
|
|
101
|
+
required: z.ZodDefault<z.ZodBoolean>;
|
|
102
|
+
labels: z.ZodDefault<z.ZodArray<z.ZodString>>;
|
|
103
|
+
}, z.core.$strip>]>>>;
|
|
104
|
+
actions: z.ZodDefault<z.ZodArray<z.ZodString>>;
|
|
105
|
+
minCpuCores: z.ZodOptional<z.ZodNumber>;
|
|
106
|
+
minRamMb: z.ZodOptional<z.ZodNumber>;
|
|
107
|
+
}, z.core.$strip>;
|
|
108
|
+
export type BuildJobRequirements = z.infer<typeof BuildJobRequirementsSchema>;
|
|
109
|
+
export declare const BuildJobMountSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
110
|
+
kind: z.ZodLiteral<"git">;
|
|
111
|
+
name: z.ZodString;
|
|
112
|
+
repository: z.ZodString;
|
|
113
|
+
ref: z.ZodOptional<z.ZodString>;
|
|
114
|
+
path: z.ZodString;
|
|
115
|
+
mode: z.ZodDefault<z.ZodEnum<{
|
|
116
|
+
"read-only": "read-only";
|
|
117
|
+
"read-write": "read-write";
|
|
118
|
+
}>>;
|
|
119
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
120
|
+
kind: z.ZodLiteral<"filesystem">;
|
|
121
|
+
name: z.ZodString;
|
|
122
|
+
adapter: z.ZodString;
|
|
123
|
+
prefix: z.ZodOptional<z.ZodString>;
|
|
124
|
+
path: z.ZodString;
|
|
125
|
+
mode: z.ZodDefault<z.ZodEnum<{
|
|
126
|
+
"read-only": "read-only";
|
|
127
|
+
"read-write": "read-write";
|
|
128
|
+
}>>;
|
|
129
|
+
sync: z.ZodDefault<z.ZodEnum<{
|
|
130
|
+
push: "push";
|
|
131
|
+
none: "none";
|
|
132
|
+
bidirectional: "bidirectional";
|
|
133
|
+
pull: "pull";
|
|
134
|
+
}>>;
|
|
135
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
136
|
+
kind: z.ZodLiteral<"artifact">;
|
|
137
|
+
name: z.ZodString;
|
|
138
|
+
path: z.ZodString;
|
|
139
|
+
mode: z.ZodDefault<z.ZodEnum<{
|
|
140
|
+
"read-only": "read-only";
|
|
141
|
+
"read-write": "read-write";
|
|
142
|
+
}>>;
|
|
143
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
144
|
+
kind: z.ZodLiteral<"temp">;
|
|
145
|
+
name: z.ZodString;
|
|
146
|
+
path: z.ZodString;
|
|
147
|
+
sizeMb: z.ZodOptional<z.ZodNumber>;
|
|
148
|
+
}, z.core.$strip>], "kind">;
|
|
149
|
+
export type BuildJobMount = z.infer<typeof BuildJobMountSchema>;
|
|
150
|
+
/** Open publish target: the storage adapter package that owns `adapter` validates the rest. */
|
|
151
|
+
export declare const BuildJobPublishTargetSchema: z.ZodObject<{
|
|
152
|
+
adapter: z.ZodString;
|
|
153
|
+
}, z.core.$loose>;
|
|
154
|
+
export type BuildJobPublishTarget = z.infer<typeof BuildJobPublishTargetSchema>;
|
|
155
|
+
export declare const BuildJobResourceRequirementsSchema: z.ZodObject<{
|
|
156
|
+
requests: z.ZodOptional<z.ZodObject<{
|
|
157
|
+
cpu: z.ZodOptional<z.ZodString>;
|
|
158
|
+
memory: z.ZodOptional<z.ZodString>;
|
|
159
|
+
}, z.core.$strip>>;
|
|
160
|
+
limits: z.ZodOptional<z.ZodObject<{
|
|
161
|
+
cpu: z.ZodOptional<z.ZodString>;
|
|
162
|
+
memory: z.ZodOptional<z.ZodString>;
|
|
163
|
+
}, z.core.$strip>>;
|
|
164
|
+
}, z.core.$strip>;
|
|
165
|
+
export declare const BuildJobTolerationSchema: z.ZodObject<{
|
|
166
|
+
key: z.ZodOptional<z.ZodString>;
|
|
167
|
+
operator: z.ZodOptional<z.ZodEnum<{
|
|
168
|
+
Exists: "Exists";
|
|
169
|
+
Equal: "Equal";
|
|
170
|
+
}>>;
|
|
171
|
+
value: z.ZodOptional<z.ZodString>;
|
|
172
|
+
effect: z.ZodOptional<z.ZodEnum<{
|
|
173
|
+
NoSchedule: "NoSchedule";
|
|
174
|
+
PreferNoSchedule: "PreferNoSchedule";
|
|
175
|
+
NoExecute: "NoExecute";
|
|
176
|
+
}>>;
|
|
177
|
+
}, z.core.$strip>;
|
|
178
|
+
export declare const LocalDockerBuildJobConfigSchema: z.ZodObject<{
|
|
179
|
+
adapter: z.ZodLiteral<"local-docker">;
|
|
180
|
+
image: z.ZodString;
|
|
181
|
+
outputDir: z.ZodDefault<z.ZodString>;
|
|
182
|
+
}, z.core.$strip>;
|
|
183
|
+
export declare const WindowsRunnerBuildJobConfigSchema: z.ZodObject<{
|
|
184
|
+
adapter: z.ZodLiteral<"windows-runner">;
|
|
185
|
+
provider: z.ZodDefault<z.ZodEnum<{
|
|
186
|
+
"azure-vm": "azure-vm";
|
|
187
|
+
"ec2-windows": "ec2-windows";
|
|
188
|
+
"self-hosted": "self-hosted";
|
|
189
|
+
}>>;
|
|
190
|
+
runnerLabel: z.ZodString;
|
|
191
|
+
image: z.ZodOptional<z.ZodString>;
|
|
192
|
+
}, z.core.$strip>;
|
|
193
|
+
/**
|
|
194
|
+
* Fleet adapter: dispatches the descriptor to the live vibes Host Action
|
|
195
|
+
* queue (`platform.hosts.createAction`) instead of provisioning its own
|
|
196
|
+
* compute. An enrolled fleet host (`fleet-daemon`) claims the
|
|
197
|
+
* resulting `host_action_runs` row and runs it via
|
|
198
|
+
* `executeBuildJobAction` — see `@vibesdotdev/platform/fleets/build-job` for the
|
|
199
|
+
* descriptor -> `CreateHostActionRunForm` translator. `hostPoolId` /
|
|
200
|
+
* `runnerLabel` here are adapter-level placement hints that the translator
|
|
201
|
+
* overlays onto the descriptor's adapter-neutral `requirements` (both use
|
|
202
|
+
* the identical shape as `BuildJobRequirementsSchema` below).
|
|
203
|
+
*/
|
|
204
|
+
export declare const FleetBuildJobConfigSchema: z.ZodObject<{
|
|
205
|
+
adapter: z.ZodLiteral<"fleet-build-job">;
|
|
206
|
+
hostPoolId: z.ZodOptional<z.ZodString>;
|
|
207
|
+
runnerLabel: z.ZodOptional<z.ZodString>;
|
|
208
|
+
}, z.core.$strip>;
|
|
209
|
+
/** Open adapter config: the adapter package that owns `adapter` validates the rest. */
|
|
210
|
+
export declare const BuildJobConfigSchema: z.ZodObject<{
|
|
211
|
+
adapter: z.ZodString;
|
|
212
|
+
}, z.core.$loose>;
|
|
213
|
+
export type BuildJobConfig = z.infer<typeof BuildJobConfigSchema>;
|
|
214
|
+
export type FleetBuildJobConfig = z.infer<typeof FleetBuildJobConfigSchema>;
|
|
215
|
+
export declare const BuildJobDescriptorSchema: z.ZodObject<{
|
|
216
|
+
id: z.ZodString;
|
|
217
|
+
name: z.ZodOptional<z.ZodString>;
|
|
218
|
+
description: z.ZodOptional<z.ZodString>;
|
|
219
|
+
tags: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
220
|
+
hardware: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
221
|
+
enabled: z.ZodOptional<z.ZodBoolean>;
|
|
222
|
+
priority: z.ZodOptional<z.ZodNumber>;
|
|
223
|
+
capabilityId: z.ZodOptional<z.ZodString>;
|
|
224
|
+
requiredContext: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
225
|
+
optionalContext: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
226
|
+
retention: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
|
|
227
|
+
maxAgeDays: z.ZodOptional<z.ZodNumber>;
|
|
228
|
+
maxEntries: z.ZodOptional<z.ZodNumber>;
|
|
229
|
+
maxBytes: z.ZodOptional<z.ZodNumber>;
|
|
230
|
+
cascadeFrom: z.ZodOptional<z.ZodString>;
|
|
231
|
+
ageField: z.ZodOptional<z.ZodString>;
|
|
232
|
+
reason: z.ZodString;
|
|
233
|
+
enforcedBy: z.ZodOptional<z.ZodString>;
|
|
234
|
+
}, z.core.$strip>]>>;
|
|
235
|
+
kind: z.ZodLiteral<"infra/build-job">;
|
|
236
|
+
source: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
237
|
+
kind: z.ZodLiteral<"git">;
|
|
238
|
+
repository: z.ZodString;
|
|
239
|
+
ref: z.ZodOptional<z.ZodString>;
|
|
240
|
+
depth: z.ZodDefault<z.ZodNumber>;
|
|
241
|
+
checkoutDir: z.ZodDefault<z.ZodString>;
|
|
242
|
+
authentication: z.ZodOptional<z.ZodObject<{
|
|
243
|
+
mode: z.ZodLiteral<"brokered">;
|
|
244
|
+
provider: z.ZodLiteral<"vibes-forge">;
|
|
245
|
+
repositoryId: z.ZodString;
|
|
246
|
+
brokerOrigin: z.ZodString;
|
|
247
|
+
serviceCredential: z.ZodObject<{
|
|
248
|
+
source: z.ZodLiteral<"secret">;
|
|
249
|
+
key: z.ZodString;
|
|
250
|
+
}, z.core.$strip>;
|
|
251
|
+
}, z.core.$strict>>;
|
|
252
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
253
|
+
kind: z.ZodLiteral<"workspace">;
|
|
254
|
+
path: z.ZodDefault<z.ZodString>;
|
|
255
|
+
}, z.core.$strip>], "kind">;
|
|
256
|
+
target: z.ZodObject<{
|
|
257
|
+
os: z.ZodEnum<{
|
|
258
|
+
linux: "linux";
|
|
259
|
+
macos: "macos";
|
|
260
|
+
windows: "windows";
|
|
261
|
+
}>;
|
|
262
|
+
arch: z.ZodEnum<{
|
|
263
|
+
x64: "x64";
|
|
264
|
+
arm64: "arm64";
|
|
265
|
+
}>;
|
|
266
|
+
libc: z.ZodOptional<z.ZodEnum<{
|
|
267
|
+
glibc: "glibc";
|
|
268
|
+
musl: "musl";
|
|
269
|
+
msvc: "msvc";
|
|
270
|
+
}>>;
|
|
271
|
+
format: z.ZodOptional<z.ZodString>;
|
|
272
|
+
}, z.core.$strip>;
|
|
273
|
+
steps: z.ZodArray<z.ZodObject<{
|
|
274
|
+
name: z.ZodString;
|
|
275
|
+
run: z.ZodString;
|
|
276
|
+
cwd: z.ZodOptional<z.ZodString>;
|
|
277
|
+
shell: z.ZodOptional<z.ZodString>;
|
|
278
|
+
}, z.core.$strip>>;
|
|
279
|
+
artifacts: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
280
|
+
path: z.ZodString;
|
|
281
|
+
name: z.ZodOptional<z.ZodString>;
|
|
282
|
+
contentType: z.ZodOptional<z.ZodString>;
|
|
283
|
+
required: z.ZodDefault<z.ZodBoolean>;
|
|
284
|
+
}, z.core.$strip>>>;
|
|
285
|
+
requirements: z.ZodOptional<z.ZodObject<{
|
|
286
|
+
hostPoolId: z.ZodOptional<z.ZodString>;
|
|
287
|
+
runnerLabel: z.ZodOptional<z.ZodString>;
|
|
288
|
+
labels: z.ZodDefault<z.ZodArray<z.ZodString>>;
|
|
289
|
+
tools: z.ZodDefault<z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
|
|
290
|
+
id: z.ZodString;
|
|
291
|
+
required: z.ZodDefault<z.ZodBoolean>;
|
|
292
|
+
labels: z.ZodDefault<z.ZodArray<z.ZodString>>;
|
|
293
|
+
}, z.core.$strip>]>>>;
|
|
294
|
+
actions: z.ZodDefault<z.ZodArray<z.ZodString>>;
|
|
295
|
+
minCpuCores: z.ZodOptional<z.ZodNumber>;
|
|
296
|
+
minRamMb: z.ZodOptional<z.ZodNumber>;
|
|
297
|
+
}, z.core.$strip>>;
|
|
298
|
+
mounts: z.ZodDefault<z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
299
|
+
kind: z.ZodLiteral<"git">;
|
|
300
|
+
name: z.ZodString;
|
|
301
|
+
repository: z.ZodString;
|
|
302
|
+
ref: z.ZodOptional<z.ZodString>;
|
|
303
|
+
path: z.ZodString;
|
|
304
|
+
mode: z.ZodDefault<z.ZodEnum<{
|
|
305
|
+
"read-only": "read-only";
|
|
306
|
+
"read-write": "read-write";
|
|
307
|
+
}>>;
|
|
308
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
309
|
+
kind: z.ZodLiteral<"filesystem">;
|
|
310
|
+
name: z.ZodString;
|
|
311
|
+
adapter: z.ZodString;
|
|
312
|
+
prefix: z.ZodOptional<z.ZodString>;
|
|
313
|
+
path: z.ZodString;
|
|
314
|
+
mode: z.ZodDefault<z.ZodEnum<{
|
|
315
|
+
"read-only": "read-only";
|
|
316
|
+
"read-write": "read-write";
|
|
317
|
+
}>>;
|
|
318
|
+
sync: z.ZodDefault<z.ZodEnum<{
|
|
319
|
+
push: "push";
|
|
320
|
+
none: "none";
|
|
321
|
+
bidirectional: "bidirectional";
|
|
322
|
+
pull: "pull";
|
|
323
|
+
}>>;
|
|
324
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
325
|
+
kind: z.ZodLiteral<"artifact">;
|
|
326
|
+
name: z.ZodString;
|
|
327
|
+
path: z.ZodString;
|
|
328
|
+
mode: z.ZodDefault<z.ZodEnum<{
|
|
329
|
+
"read-only": "read-only";
|
|
330
|
+
"read-write": "read-write";
|
|
331
|
+
}>>;
|
|
332
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
333
|
+
kind: z.ZodLiteral<"temp">;
|
|
334
|
+
name: z.ZodString;
|
|
335
|
+
path: z.ZodString;
|
|
336
|
+
sizeMb: z.ZodOptional<z.ZodNumber>;
|
|
337
|
+
}, z.core.$strip>], "kind">>>;
|
|
338
|
+
publish: z.ZodOptional<z.ZodObject<{
|
|
339
|
+
adapter: z.ZodString;
|
|
340
|
+
}, z.core.$loose>>;
|
|
341
|
+
env: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
342
|
+
name: z.ZodString;
|
|
343
|
+
public: z.ZodOptional<z.ZodBoolean>;
|
|
344
|
+
required: z.ZodOptional<z.ZodBoolean>;
|
|
345
|
+
value: z.ZodOptional<z.ZodString>;
|
|
346
|
+
secret: z.ZodOptional<z.ZodBoolean>;
|
|
347
|
+
description: z.ZodOptional<z.ZodString>;
|
|
348
|
+
storeKey: z.ZodOptional<z.ZodString>;
|
|
349
|
+
storeBinding: z.ZodOptional<z.ZodBoolean>;
|
|
350
|
+
}, z.core.$strip>>>;
|
|
351
|
+
config: z.ZodOptional<z.ZodObject<{
|
|
352
|
+
adapter: z.ZodString;
|
|
353
|
+
}, z.core.$loose>>;
|
|
354
|
+
}, z.core.$strip>;
|
|
355
|
+
export type BuildJobDescriptor = z.infer<typeof BuildJobDescriptorSchema>;
|
|
356
|
+
export type BuildJobDescriptorInput = z.input<typeof BuildJobDescriptorSchema>;
|
|
357
|
+
/** Facts a build-job run reports: JSON values only. */
|
|
358
|
+
export declare const BuildJobRunMetadataSchema: z.ZodRecord<z.ZodString, z.ZodType<import("@vibesdotdev/kernel/bootstrap").JsonValue, import("@vibesdotdev/kernel/bootstrap").JsonValue, z.core.$ZodTypeInternals<import("@vibesdotdev/kernel/bootstrap").JsonValue, import("@vibesdotdev/kernel/bootstrap").JsonValue>>>;
|
|
359
|
+
export type BuildJobRunMetadata = z.infer<typeof BuildJobRunMetadataSchema>;
|
|
360
|
+
export interface BuildJobRunResult {
|
|
361
|
+
id: string;
|
|
362
|
+
status: 'queued' | 'running' | 'succeeded' | 'failed';
|
|
363
|
+
artifacts?: BuildJobArtifact[];
|
|
364
|
+
logsUrl?: string;
|
|
365
|
+
metadata?: BuildJobRunMetadata;
|
|
366
|
+
}
|
|
367
|
+
export interface BuildJobImplementation {
|
|
368
|
+
generateConfig?(descriptor?: BuildJobDescriptor): BuildJobConfig | undefined;
|
|
369
|
+
run?(descriptor: BuildJobDescriptor): Promise<BuildJobRunResult>;
|
|
370
|
+
}
|
|
371
|
+
declare class DefaultBuildJobImplementation implements BuildJobImplementation {
|
|
372
|
+
readonly descriptor: RuntimeDescriptor;
|
|
373
|
+
readonly context: KindContext;
|
|
374
|
+
/** The descriptor as this kind's schema reads it. */
|
|
375
|
+
readonly config: BuildJobDescriptor;
|
|
376
|
+
constructor(descriptor: RuntimeDescriptor, context: KindContext);
|
|
377
|
+
generateConfig(descriptor?: BuildJobDescriptor): BuildJobConfig | undefined;
|
|
378
|
+
}
|
|
379
|
+
export declare const buildJobKind: import("@vibesdotdev/kernel").RuntimeKindDescriptorRecord<DefaultBuildJobImplementation>;
|
|
380
|
+
export {};
|
|
381
|
+
//# sourceMappingURL=build-job.kind.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"build-job.kind.d.ts","sourceRoot":"","sources":["../../src/kinds/build-job.kind.ts"],"names":[],"mappings":"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"}
|
|
@@ -0,0 +1,216 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Kind: infra/build-job
|
|
3
|
+
*
|
|
4
|
+
* Provider-neutral descriptor for reproducible release builds. Adapter
|
|
5
|
+
* packages map this shape onto DOKS Kubernetes Jobs, local Docker runs,
|
|
6
|
+
* Windows VM runners, or another execution substrate.
|
|
7
|
+
*/
|
|
8
|
+
import * as z from 'zod/v4';
|
|
9
|
+
import { JsonValueSchema } from '@vibesdotdev/kernel/schemas/json';
|
|
10
|
+
import { createRuntimeKind } from '@vibesdotdev/kernel/factory/kind';
|
|
11
|
+
import { RuntimeDescriptorSchema } from '@vibesdotdev/kernel/schemas/descriptor';
|
|
12
|
+
import { readKindDescriptor } from "./read-descriptor.js";
|
|
13
|
+
import { deploymentEnvRequirementSchema } from "../schemas.js";
|
|
14
|
+
import { INFRA_DISCOVERY_PATTERNS } from "./discovery.js";
|
|
15
|
+
export const BuildTargetOsSchema = z.enum(['linux', 'macos', 'windows']);
|
|
16
|
+
export const BuildTargetArchSchema = z.enum(['x64', 'arm64']);
|
|
17
|
+
export const BuildJobTargetSchema = z.object({
|
|
18
|
+
os: BuildTargetOsSchema,
|
|
19
|
+
arch: BuildTargetArchSchema,
|
|
20
|
+
libc: z.enum(['glibc', 'musl', 'msvc']).optional(),
|
|
21
|
+
format: z.string().min(1).optional()
|
|
22
|
+
});
|
|
23
|
+
/**
|
|
24
|
+
* A build never carries a repository password/token. It carries only enough
|
|
25
|
+
* authority metadata for the execution adapter to ask the platform broker for
|
|
26
|
+
* one operation-scoped read credential at checkout time.
|
|
27
|
+
*/
|
|
28
|
+
export const BuildJobGitAuthenticationSchema = z
|
|
29
|
+
.object({
|
|
30
|
+
mode: z.literal('brokered'),
|
|
31
|
+
provider: z.literal('vibes-forge'),
|
|
32
|
+
repositoryId: z.string().uuid(),
|
|
33
|
+
brokerOrigin: z.string().url(),
|
|
34
|
+
serviceCredential: z.object({
|
|
35
|
+
source: z.literal('secret'),
|
|
36
|
+
key: z.string().regex(/^[_A-Z0-9]+$/)
|
|
37
|
+
})
|
|
38
|
+
})
|
|
39
|
+
.strict();
|
|
40
|
+
const BuildJobGitSourceSchema = z
|
|
41
|
+
.object({
|
|
42
|
+
kind: z.literal('git'),
|
|
43
|
+
repository: z.string().min(1),
|
|
44
|
+
ref: z.string().min(1).optional(),
|
|
45
|
+
depth: z.number().int().positive().default(1),
|
|
46
|
+
checkoutDir: z.string().min(1).default('/workspace/source'),
|
|
47
|
+
authentication: BuildJobGitAuthenticationSchema.optional()
|
|
48
|
+
})
|
|
49
|
+
.strict()
|
|
50
|
+
.superRefine((source, ctx) => {
|
|
51
|
+
// SCP-style SSH repositories (`git@host:path`) are not URLs and carry no userinfo password.
|
|
52
|
+
if (!URL.canParse(source.repository))
|
|
53
|
+
return;
|
|
54
|
+
const repository = new URL(source.repository);
|
|
55
|
+
const sshTransport = repository.protocol === 'ssh:';
|
|
56
|
+
if (repository.password || (repository.username && !sshTransport)) {
|
|
57
|
+
ctx.addIssue({
|
|
58
|
+
code: 'custom',
|
|
59
|
+
path: ['repository'],
|
|
60
|
+
message: 'git source URLs must never embed credentials; SSH transport may carry only its public login name'
|
|
61
|
+
});
|
|
62
|
+
}
|
|
63
|
+
});
|
|
64
|
+
export const BuildJobSourceSchema = z.discriminatedUnion('kind', [
|
|
65
|
+
BuildJobGitSourceSchema,
|
|
66
|
+
z.object({
|
|
67
|
+
kind: z.literal('workspace'),
|
|
68
|
+
path: z.string().min(1).default('.')
|
|
69
|
+
})
|
|
70
|
+
]);
|
|
71
|
+
export const BuildJobStepSchema = z.object({
|
|
72
|
+
name: z.string().min(1),
|
|
73
|
+
run: z.string().min(1),
|
|
74
|
+
cwd: z.string().min(1).optional(),
|
|
75
|
+
shell: z.string().min(1).optional()
|
|
76
|
+
});
|
|
77
|
+
export const BuildJobArtifactSchema = z.object({
|
|
78
|
+
path: z.string().min(1),
|
|
79
|
+
name: z.string().min(1).optional(),
|
|
80
|
+
contentType: z.string().min(1).optional(),
|
|
81
|
+
required: z.boolean().default(true)
|
|
82
|
+
});
|
|
83
|
+
export const BuildJobToolRequirementSchema = z.union([
|
|
84
|
+
z.string().min(1),
|
|
85
|
+
z.object({
|
|
86
|
+
id: z.string().min(1),
|
|
87
|
+
required: z.boolean().default(true),
|
|
88
|
+
labels: z.array(z.string().min(1)).default([])
|
|
89
|
+
})
|
|
90
|
+
]);
|
|
91
|
+
export const BuildJobRequirementsSchema = z.object({
|
|
92
|
+
hostPoolId: z.string().min(1).optional(),
|
|
93
|
+
runnerLabel: z.string().min(1).optional(),
|
|
94
|
+
labels: z.array(z.string().min(1)).default([]),
|
|
95
|
+
tools: z.array(BuildJobToolRequirementSchema).default([]),
|
|
96
|
+
actions: z.array(z.string().min(1)).default([]),
|
|
97
|
+
minCpuCores: z.number().int().positive().optional(),
|
|
98
|
+
minRamMb: z.number().int().positive().optional()
|
|
99
|
+
});
|
|
100
|
+
export const BuildJobMountSchema = z.discriminatedUnion('kind', [
|
|
101
|
+
z.object({
|
|
102
|
+
kind: z.literal('git'),
|
|
103
|
+
name: z.string().min(1),
|
|
104
|
+
repository: z.string().min(1),
|
|
105
|
+
ref: z.string().min(1).optional(),
|
|
106
|
+
path: z.string().min(1),
|
|
107
|
+
mode: z.enum(['read-only', 'read-write']).default('read-only')
|
|
108
|
+
}),
|
|
109
|
+
z.object({
|
|
110
|
+
kind: z.literal('filesystem'),
|
|
111
|
+
name: z.string().min(1),
|
|
112
|
+
adapter: z.string().min(1),
|
|
113
|
+
prefix: z.string().optional(),
|
|
114
|
+
path: z.string().min(1),
|
|
115
|
+
mode: z.enum(['read-only', 'read-write']).default('read-write'),
|
|
116
|
+
sync: z.enum(['none', 'pull', 'push', 'bidirectional']).default('none')
|
|
117
|
+
}),
|
|
118
|
+
z.object({
|
|
119
|
+
kind: z.literal('artifact'),
|
|
120
|
+
name: z.string().min(1),
|
|
121
|
+
path: z.string().min(1),
|
|
122
|
+
mode: z.enum(['read-only', 'read-write']).default('read-write')
|
|
123
|
+
}),
|
|
124
|
+
z.object({
|
|
125
|
+
kind: z.literal('temp'),
|
|
126
|
+
name: z.string().min(1),
|
|
127
|
+
path: z.string().min(1),
|
|
128
|
+
sizeMb: z.number().int().positive().optional()
|
|
129
|
+
})
|
|
130
|
+
]);
|
|
131
|
+
/** Open publish target: the storage adapter package that owns `adapter` validates the rest. */
|
|
132
|
+
export const BuildJobPublishTargetSchema = z.looseObject({ adapter: z.string().min(1) });
|
|
133
|
+
export const BuildJobResourceRequirementsSchema = z.object({
|
|
134
|
+
requests: z
|
|
135
|
+
.object({
|
|
136
|
+
cpu: z.string().min(1).optional(),
|
|
137
|
+
memory: z.string().min(1).optional()
|
|
138
|
+
})
|
|
139
|
+
.optional(),
|
|
140
|
+
limits: z
|
|
141
|
+
.object({
|
|
142
|
+
cpu: z.string().min(1).optional(),
|
|
143
|
+
memory: z.string().min(1).optional()
|
|
144
|
+
})
|
|
145
|
+
.optional()
|
|
146
|
+
});
|
|
147
|
+
export const BuildJobTolerationSchema = z.object({
|
|
148
|
+
key: z.string().min(1).optional(),
|
|
149
|
+
operator: z.enum(['Exists', 'Equal']).optional(),
|
|
150
|
+
value: z.string().optional(),
|
|
151
|
+
effect: z.enum(['NoSchedule', 'PreferNoSchedule', 'NoExecute']).optional()
|
|
152
|
+
});
|
|
153
|
+
export const LocalDockerBuildJobConfigSchema = z.object({
|
|
154
|
+
adapter: z.literal('local-docker'),
|
|
155
|
+
image: z.string().min(1),
|
|
156
|
+
outputDir: z.string().min(1).default('artifacts/build-jobs')
|
|
157
|
+
});
|
|
158
|
+
export const WindowsRunnerBuildJobConfigSchema = z.object({
|
|
159
|
+
adapter: z.literal('windows-runner'),
|
|
160
|
+
provider: z.enum(['azure-vm', 'ec2-windows', 'self-hosted']).default('self-hosted'),
|
|
161
|
+
runnerLabel: z.string().min(1),
|
|
162
|
+
image: z.string().min(1).optional()
|
|
163
|
+
});
|
|
164
|
+
/**
|
|
165
|
+
* Fleet adapter: dispatches the descriptor to the live vibes Host Action
|
|
166
|
+
* queue (`platform.hosts.createAction`) instead of provisioning its own
|
|
167
|
+
* compute. An enrolled fleet host (`fleet-daemon`) claims the
|
|
168
|
+
* resulting `host_action_runs` row and runs it via
|
|
169
|
+
* `executeBuildJobAction` — see `@vibesdotdev/platform/fleets/build-job` for the
|
|
170
|
+
* descriptor -> `CreateHostActionRunForm` translator. `hostPoolId` /
|
|
171
|
+
* `runnerLabel` here are adapter-level placement hints that the translator
|
|
172
|
+
* overlays onto the descriptor's adapter-neutral `requirements` (both use
|
|
173
|
+
* the identical shape as `BuildJobRequirementsSchema` below).
|
|
174
|
+
*/
|
|
175
|
+
export const FleetBuildJobConfigSchema = z.object({
|
|
176
|
+
adapter: z.literal('fleet-build-job'),
|
|
177
|
+
hostPoolId: z.string().min(1).optional(),
|
|
178
|
+
runnerLabel: z.string().min(1).optional()
|
|
179
|
+
});
|
|
180
|
+
/** Open adapter config: the adapter package that owns `adapter` validates the rest. */
|
|
181
|
+
export const BuildJobConfigSchema = z.looseObject({ adapter: z.string().min(1) });
|
|
182
|
+
export const BuildJobDescriptorSchema = RuntimeDescriptorSchema.extend({
|
|
183
|
+
kind: z.literal('infra/build-job'),
|
|
184
|
+
source: BuildJobSourceSchema,
|
|
185
|
+
target: BuildJobTargetSchema,
|
|
186
|
+
steps: z.array(BuildJobStepSchema).min(1),
|
|
187
|
+
artifacts: z.array(BuildJobArtifactSchema).default([]),
|
|
188
|
+
requirements: BuildJobRequirementsSchema.optional(),
|
|
189
|
+
mounts: z.array(BuildJobMountSchema).default([]),
|
|
190
|
+
publish: BuildJobPublishTargetSchema.optional(),
|
|
191
|
+
env: z.array(deploymentEnvRequirementSchema).optional(),
|
|
192
|
+
config: BuildJobConfigSchema.optional()
|
|
193
|
+
});
|
|
194
|
+
/** Facts a build-job run reports: JSON values only. */
|
|
195
|
+
export const BuildJobRunMetadataSchema = z.record(z.string(), JsonValueSchema);
|
|
196
|
+
class DefaultBuildJobImplementation {
|
|
197
|
+
descriptor;
|
|
198
|
+
context;
|
|
199
|
+
/** The descriptor as this kind's schema reads it. */
|
|
200
|
+
config;
|
|
201
|
+
constructor(descriptor, context) {
|
|
202
|
+
this.descriptor = descriptor;
|
|
203
|
+
this.context = context;
|
|
204
|
+
this.config = readKindDescriptor(BuildJobDescriptorSchema, descriptor);
|
|
205
|
+
}
|
|
206
|
+
generateConfig(descriptor = this.config) {
|
|
207
|
+
return descriptor.config;
|
|
208
|
+
}
|
|
209
|
+
}
|
|
210
|
+
export const buildJobKind = createRuntimeKind({
|
|
211
|
+
id: 'infra/build-job',
|
|
212
|
+
descriptorSchema: BuildJobDescriptorSchema,
|
|
213
|
+
defaultImplementation: DefaultBuildJobImplementation,
|
|
214
|
+
discoveryPatterns: INFRA_DISCOVERY_PATTERNS
|
|
215
|
+
});
|
|
216
|
+
//# sourceMappingURL=build-job.kind.js.map
|