blogwright 0.1.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/LICENSE +24 -0
- package/README.md +12 -0
- package/agent/Dockerfile +20 -0
- package/agent/agent-manifest.json +3 -0
- package/agent/server.js +7935 -0
- package/dist/adapters/fetch-ping.d.ts +9 -0
- package/dist/adapters/fetch-ping.js +26 -0
- package/dist/adapters/fetch-ping.js.map +1 -0
- package/dist/adapters/process-vcs.d.ts +12 -0
- package/dist/adapters/process-vcs.js +49 -0
- package/dist/adapters/process-vcs.js.map +1 -0
- package/dist/agent-package.d.ts +19 -0
- package/dist/agent-package.js +49 -0
- package/dist/agent-package.js.map +1 -0
- package/dist/bin.d.ts +2 -0
- package/dist/bin.js +14 -0
- package/dist/bin.js.map +1 -0
- package/dist/cli.d.ts +6 -0
- package/dist/cli.js +249 -0
- package/dist/cli.js.map +1 -0
- package/dist/commands.d.ts +31 -0
- package/dist/commands.js +269 -0
- package/dist/commands.js.map +1 -0
- package/dist/context.d.ts +50 -0
- package/dist/context.js +77 -0
- package/dist/context.js.map +1 -0
- package/dist/deploy.d.ts +57 -0
- package/dist/deploy.js +247 -0
- package/dist/deploy.js.map +1 -0
- package/dist/graph.d.ts +20 -0
- package/dist/graph.js +73 -0
- package/dist/graph.js.map +1 -0
- package/dist/init.d.ts +4 -0
- package/dist/init.js +92 -0
- package/dist/init.js.map +1 -0
- package/dist/logger.d.ts +18 -0
- package/dist/logger.js +34 -0
- package/dist/logger.js.map +1 -0
- package/dist/microvms.d.ts +15 -0
- package/dist/microvms.js +56 -0
- package/dist/microvms.js.map +1 -0
- package/dist/nodes.d.ts +34 -0
- package/dist/nodes.js +858 -0
- package/dist/nodes.js.map +1 -0
- package/dist/ports.d.ts +25 -0
- package/dist/ports.js +7 -0
- package/dist/ports.js.map +1 -0
- package/dist/render.d.ts +33 -0
- package/dist/render.js +81 -0
- package/dist/render.js.map +1 -0
- package/dist/repo.d.ts +25 -0
- package/dist/repo.js +75 -0
- package/dist/repo.js.map +1 -0
- package/dist/rkey.d.ts +6 -0
- package/dist/rkey.js +7 -0
- package/dist/rkey.js.map +1 -0
- package/dist/seo.d.ts +15 -0
- package/dist/seo.js +30 -0
- package/dist/seo.js.map +1 -0
- package/dist/test-support.d.ts +44 -0
- package/dist/test-support.js +120 -0
- package/dist/test-support.js.map +1 -0
- package/package.json +57 -0
package/dist/nodes.d.ts
ADDED
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import type { OpsContext } from './context.js';
|
|
2
|
+
import type { ResourceNode } from './graph.js';
|
|
3
|
+
export type BuilderImageAction = 'create' | 'update' | 'skip';
|
|
4
|
+
/**
|
|
5
|
+
* Decide what a builder-image reconcile should do: create when the image is missing or
|
|
6
|
+
* being deleted, skip when a healthy image already matches the current agent bundle and
|
|
7
|
+
* log group, otherwise update (agent bundle changed, log group changed, or last build
|
|
8
|
+
* unhealthy). Pure so the decision is unit-testable independent of the AWS calls.
|
|
9
|
+
*/
|
|
10
|
+
export declare function builderImageAction(image: {
|
|
11
|
+
state: string;
|
|
12
|
+
} | undefined, recorded: {
|
|
13
|
+
agentHash?: string | undefined;
|
|
14
|
+
logGroup?: string | undefined;
|
|
15
|
+
}, hash: string, logGroup: string): BuilderImageAction;
|
|
16
|
+
/**
|
|
17
|
+
* Create, rebuild, or leave the MicroVM builder image, depending on what's deployed:
|
|
18
|
+
* create it if missing, rebuild it if the agent bundle (or its log group) changed or the
|
|
19
|
+
* last build is unhealthy, otherwise no-op. Idempotent and cheap in the common case (a
|
|
20
|
+
* single GetMicrovmImage + hash compare), so it's safe to run before every deploy — which
|
|
21
|
+
* is how build-agent changes propagate through CI without a separate `bootstrap`.
|
|
22
|
+
*/
|
|
23
|
+
export declare function reconcileBuilderImage(ctx: OpsContext): Promise<void>;
|
|
24
|
+
/**
|
|
25
|
+
* The workflow's OIDC subject claim, scoped per environment to match how each one
|
|
26
|
+
* deploys: previews from any PR ref; staging from pushes to main; production from the
|
|
27
|
+
* `production` GitHub Environment (release-gated — see production.yml), which lets
|
|
28
|
+
* deploys be gated behind environment protection rules.
|
|
29
|
+
*/
|
|
30
|
+
export declare function oidcSubClaim(repo: string, env: string, preview: boolean): string;
|
|
31
|
+
/** The deploy role's inline policy statements (exported for tests). */
|
|
32
|
+
export declare function oidcRolePolicyStatements(ctx: OpsContext): object[];
|
|
33
|
+
/** Build the full node set for the current context (production or preview stack). */
|
|
34
|
+
export declare function buildNodes(ctx: OpsContext): ResourceNode[];
|