@aifabrix/builder 2.55.2 → 2.57.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/lib/agent-kit/session-report.js +76 -0
- package/lib/agent-kit/start.js +124 -57
- package/lib/agent-kit/tmux-sessions.js +163 -0
- package/lib/api/environments.api.js +38 -0
- package/lib/api/marketplace-bootstrap.api.js +31 -0
- package/lib/api/pipeline.api.js +32 -3
- package/lib/app/deploy.js +6 -5
- package/lib/cli/setup-app.js +7 -6
- package/lib/cli/setup-environment.js +76 -19
- package/lib/cli/setup-external-system-help.js +15 -3
- package/lib/cli/setup-external-system.js +21 -3
- package/lib/commands/agent-kit-help.js +32 -15
- package/lib/commands/agent-kit.js +90 -8
- package/lib/commands/repair-datasource-auto-rbac.js +4 -9
- package/lib/commands/upload-openapi-sync-followup.js +59 -0
- package/lib/commands/upload-qualification-client.js +131 -0
- package/lib/commands/upload-qualification-followups.js +104 -0
- package/lib/commands/upload-qualification-poll.js +143 -0
- package/lib/commands/upload.js +37 -156
- package/lib/deployment/deploy-poll-ui.js +14 -10
- package/lib/deployment/deployer-status.js +4 -4
- package/lib/deployment/installation/azure-infra-stage.js +160 -0
- package/lib/deployment/installation/azure-preflight.js +102 -0
- package/lib/deployment/installation/azure-readiness.js +71 -0
- package/lib/deployment/installation/docker-register.js +112 -0
- package/lib/deployment/installation/environment-auth.js +76 -0
- package/lib/deployment/installation/environment-manifest.js +165 -0
- package/lib/deployment/installation/environment-stage.js +191 -0
- package/lib/deployment/installation/index.js +39 -0
- package/lib/deployment/installation/infra-catalog.js +165 -0
- package/lib/deployment/installation/infra-manifest.js +161 -0
- package/lib/deployment/installation/infra-projection.js +86 -0
- package/lib/deployment/installation/public-ip.js +65 -0
- package/lib/deployment/installation/stage-input.js +169 -0
- package/lib/deployment/installation/stage-output.js +53 -0
- package/lib/deployment/installation/workspace-env.js +76 -0
- package/lib/deployment/installation/workspace-files.js +178 -0
- package/lib/deployment/installation/workspace-schema.js +40 -0
- package/lib/deployment/installation/workspace-secrets.js +66 -0
- package/lib/deployment/installation/workspace.js +128 -0
- package/lib/deployment/marketplace-environment.js +305 -0
- package/lib/external-system/deploy.js +46 -51
- package/lib/generator/builders.js +4 -0
- package/lib/generator/helpers.js +55 -99
- package/lib/generator/index.js +0 -4
- package/lib/generator/split-variables.js +11 -5
- package/lib/internal/fs-real-sync.js +29 -0
- package/lib/programmatic/builder-api-request.js +8 -4
- package/lib/programmatic/capability-registry.js +2 -0
- package/lib/programmatic/get-deploy-status.js +45 -0
- package/lib/programmatic/get-upload-status.js +45 -0
- package/lib/programmatic/http-accepted-response.js +31 -0
- package/lib/programmatic/openapi-descriptions.js +14 -4
- package/lib/programmatic/request-timeout.js +21 -15
- package/lib/programmatic/route-handler-map.js +6 -0
- package/lib/programmatic/run-deploy.js +7 -3
- package/lib/programmatic/run-upload.js +11 -7
- package/lib/role-assistant/package-validate.js +4 -0
- package/lib/role-assistant/test-runner-clarification-resubmit.js +149 -0
- package/lib/role-assistant/test-runner.js +14 -17
- package/lib/schema/application-schema.json +20 -2
- package/lib/schema/infra-parameter.schema.json +7 -0
- package/lib/schema/infra.parameter.yaml +32 -43
- package/lib/schema/infrastructure-schema.json +1480 -399
- package/lib/schema/installation-environment.schema.json +601 -0
- package/lib/utils/cli-utils.js +3 -2
- package/lib/utils/qualification-poll-ui.js +136 -0
- package/lib/utils/variable-transformer.js +3 -0
- package/lib/validation/required-variables.js +41 -0
- package/lib/validation/validator.js +8 -5
- package/package.json +7 -2
- package/templates/README.md +4 -0
- package/templates/agent-kit/instructions/AGENTKIT.md +6 -6
- package/templates/agent-kit/skills/shared/hosts.md +10 -10
- package/templates/applications/builder-api/env.template +4 -0
- package/templates/applications/dataplane/application.yaml +1 -1
- package/templates/applications/dataplane/env.template +1 -1
- package/templates/applications/keycloak/Dockerfile +12 -5
- package/templates/applications/keycloak/application.yaml +2 -2
- package/templates/applications/keycloak/cimd-lenient-parse/AbstractClientIdMetadataDocumentExecutor.java +3 -3
- package/templates/applications/keycloak/cimd-lenient-parse/SOURCE.md +6 -6
- package/templates/applications/keycloak/env.template +13 -1
- package/templates/applications/miso-controller/application.yaml +3 -2
- package/templates/applications/miso-controller/env.template +28 -22
- package/templates/marketplace/createUiDefinition.json +77 -0
- package/templates/marketplace/install.parameters.example.json +9 -0
- package/templates/marketplace/main.json +4087 -0
- package/lib/generator/deploy-manifest-azure-kv.js +0 -81
|
@@ -1,81 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Map url:// placeholders and Traefik host templates to Azure Key Vault secret names
|
|
3
|
-
* in deployment manifests (Miso Controller / App Service @Microsoft.KeyVault references).
|
|
4
|
-
*
|
|
5
|
-
* @fileoverview Plan 122 — deploy JSON must not ship url:// or ${DEV_USERNAME} for Azure
|
|
6
|
-
* @author AI Fabrix Team
|
|
7
|
-
* @version 1.0.0
|
|
8
|
-
*/
|
|
9
|
-
|
|
10
|
-
'use strict';
|
|
11
|
-
|
|
12
|
-
const { parseUrlToken } = require('../utils/url-declarative-token-parse');
|
|
13
|
-
|
|
14
|
-
/**
|
|
15
|
-
* @param {string|undefined} surface
|
|
16
|
-
* @param {string} subject
|
|
17
|
-
* @param {boolean} isPublic
|
|
18
|
-
* @returns {string|undefined} Secret name when surface is vdir/host
|
|
19
|
-
*/
|
|
20
|
-
function secretNameFromSurface(surface, subject, isPublic) {
|
|
21
|
-
if (surface === 'vdir') {
|
|
22
|
-
return `${subject}-vdir-${isPublic ? 'public' : 'internal'}`;
|
|
23
|
-
}
|
|
24
|
-
if (surface === 'host') {
|
|
25
|
-
return `${subject}-host-${isPublic ? 'public' : 'internal'}`;
|
|
26
|
-
}
|
|
27
|
-
return undefined;
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
/**
|
|
31
|
-
* Key Vault secret name for a url:// token (path after url://).
|
|
32
|
-
* Aligns with infrastructure/bicep (e.g. keycloak-web-server-url, miso-controller-web-server-url).
|
|
33
|
-
*
|
|
34
|
-
* @param {string} ownerAppKey - application.yaml app.key for the manifest being generated
|
|
35
|
-
* @param {string} token - Token after url:// (no scheme)
|
|
36
|
-
* @returns {string}
|
|
37
|
-
*/
|
|
38
|
-
function urlTokenToKeyVaultSecretName(ownerAppKey, token) {
|
|
39
|
-
const selfKey = String(ownerAppKey || '').trim() || 'app';
|
|
40
|
-
const t = String(token || '').trim();
|
|
41
|
-
if (!t) {
|
|
42
|
-
throw new Error('Empty url:// reference (expected a token after url://)');
|
|
43
|
-
}
|
|
44
|
-
const { targetKey, kind, surface } = parseUrlToken(t);
|
|
45
|
-
const isPublic = kind === 'public';
|
|
46
|
-
const subject = targetKey ? String(targetKey).trim() : selfKey;
|
|
47
|
-
|
|
48
|
-
const fromSurface = secretNameFromSurface(surface, subject, isPublic);
|
|
49
|
-
if (fromSurface !== undefined) {
|
|
50
|
-
return fromSurface;
|
|
51
|
-
}
|
|
52
|
-
if (targetKey === 'keycloak' || (!targetKey && selfKey === 'keycloak')) {
|
|
53
|
-
return isPublic ? 'keycloak-web-server-url' : 'keycloak-internal-server-url';
|
|
54
|
-
}
|
|
55
|
-
if (!targetKey) {
|
|
56
|
-
return isPublic ? `${selfKey}-web-server-url` : `${selfKey}-internal-server-url`;
|
|
57
|
-
}
|
|
58
|
-
return isPublic ? `${subject}-web-server-url` : `${subject}-internal-server-url`;
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
/**
|
|
62
|
-
* Replace Traefik-style host templates with a Key Vault secret name consumed by Azure provisioning.
|
|
63
|
-
*
|
|
64
|
-
* @param {Object} deployment - Deployment manifest (mutated in place)
|
|
65
|
-
* @returns {void}
|
|
66
|
-
*/
|
|
67
|
-
function rewriteFrontDoorHostForAzureDeploy(deployment) {
|
|
68
|
-
if (!deployment || !deployment.frontDoorRouting || typeof deployment.frontDoorRouting.host !== 'string') {
|
|
69
|
-
return;
|
|
70
|
-
}
|
|
71
|
-
const h = deployment.frontDoorRouting.host;
|
|
72
|
-
if (/\$\{(DEV_USERNAME|REMOTE_HOST)\}/.test(h)) {
|
|
73
|
-
const key = deployment.key || 'app';
|
|
74
|
-
deployment.frontDoorRouting.host = `${key}-frontdoor-routing-host`;
|
|
75
|
-
}
|
|
76
|
-
}
|
|
77
|
-
|
|
78
|
-
module.exports = {
|
|
79
|
-
urlTokenToKeyVaultSecretName,
|
|
80
|
-
rewriteFrontDoorHostForAzureDeploy
|
|
81
|
-
};
|